From 180eabf30b51fbbb5b2af44a2b281b9ac23eb1ba Mon Sep 17 00:00:00 2001 From: Daniele Cinti Date: Wed, 23 Mar 2016 18:06:41 +0100 Subject: [PATCH] Built motion from commit 3f4d3c3.|0.0.70 --- public/app/116b9f4e.app.js | 51 ++++++++++++++++++++++++++++++++ public/app/32a97909.app.js | 51 -------------------------------- public/index.html | 2 +- release-notes/changelog_0.0.70.txt | 10 ++---- server/api/update/update.controller.js | 6 ++-- 5 files changed, 58 insertions(+), 62 deletions(-) create mode 100644 public/app/116b9f4e.app.js delete mode 100644 public/app/32a97909.app.js diff --git a/public/app/116b9f4e.app.js b/public/app/116b9f4e.app.js new file mode 100644 index 0000000..235c257 --- /dev/null +++ b/public/app/116b9f4e.app.js @@ -0,0 +1,51 @@ +"use strict";angular.module("xCallyShuttleApp",["adf","adf.structures.base","adf.widget.clock","adf.widget.iframe","adf.widget.counter","adf.widget.pie-chart","angular-md5","angular.filter","angularFileUpload","btford.socket-io","chart.js","checklist-model","colorpicker.module","frapontillo.bootstrap-switch","infinite-scroll","LocalStorageModule","mgo-angular-wizard","ng-slide-down","ngAnimate","ngBootstrap","ngCookies","ngCsv","ngFileSaver","ngJsTree","ngMap","ngPapaParse","ngResource","ngSanitize","notification","oc.lazyLoad","pascalprecht.translate","pdf","remoteValidation","smart-table","sprintf","textAngular","timer","toastr","permission","ui-notification","ui.bootstrap.modal","ui.bootstrap.dropdown","ui.bootstrap.popover","ui.bootstrap.timepicker","ui.bootstrap.tooltip","ui.bootstrap.tpls","ui.bootstrap.accordion","ui.bootstrap.progressbar","ui.bootstrap.typeahead","ui.grid","ui.grid.autoResize","ui.grid.draggable-rows","ui.grid.exporter","ui.grid.grouping","ui.grid.moveColumns","ui.grid.pagination","ui.grid.treeView","ui.grid.selection","ui.grid.exporter","ui.grid.resizeColumns","ui.router","ui.navbar","ui.select","ui.sortable","xeditable","ngAudio","truncate","ngScrollbars","ngEmoticons","angularSpinner","builder","builder.components","validator","angular-clipboard","ng-code-mirror","angularMoment"]).config(["$stateProvider","$urlRouterProvider","$locationProvider","$httpProvider","$translateProvider","localStorageServiceProvider","dashboardProvider","ScrollBarsProvider",function(a,b,c,d,e,f,g,h){b.otherwise("/dashboard/voice"),e.useStaticFilesLoader({prefix:"assets/languages/locale-",suffix:".json"}),e.preferredLanguage("en_EN"),e.useLocalStorage(),e.useSanitizeValueStrategy("sanitize"),c.html5Mode(!0),d.interceptors.push("authInterceptor"),g.structure("4-4-4",{rows:[{columns:[{styleClass:"col-md-4"},{styleClass:"col-md-4"},{styleClass:"col-md-4"}]}]}).structure("3-3-3-3",{rows:[{columns:[{styleClass:"col-md-3"},{styleClass:"col-md-3"},{styleClass:"col-md-3"},{styleClass:"col-md-3"}]}]}),f.setPrefix("xcally"),h.defaults={scrollButtons:{scrollAmount:"auto",enable:!0},axis:"y"}}]).factory("settings",["$rootScope","$interval","License","localStorageService",function(a,b,c,d){return a.settings={patternName:"[A-Za-z0-9._]+",layout:{pageSidebarClosed:d.get("sidebarClosed")||!1,pageQuickSidebarOpened:!1,pageBodySolid:!1,pageAutoScrollOnLoad:1e3}},c.get(function(b){b.license&&(a.license=b.license,a.soundPath=b.soundPath)}),a.settings}]).factory("authInterceptor",["$rootScope","$q","$cookieStore",function(a,b,c){return{request:function(a){return a.headers=a.headers||{},c.get("token")&&(a.headers.Authorization="Bearer "+c.get("token")),a}}}]).run(["$rootScope","$location","$state","$stateParams","$window","$q","$http","Auth","RoleStore","editableThemes","editableOptions",function(a,b,c,d,e,f,g,h,i,j,k){g.get("/api/settings/1").success(function(b){a.license=b.license}).error(function(a){console.error(a)}),a.$state=c,a.$stateParams=d,j.bs3.inputClass="input-sm",j.bs3.buttonsClass="btn-xs",k.theme="bs3",a.online=navigator.onLine,e.addEventListener("offline",function(){a.$apply(function(){a.online=!1})},!1),e.addEventListener("online",function(){a.$apply(function(){a.online=!0})},!1),a.$on("$stateChangeStart",function(a,c){h.isLoggedInAsync(function(a){c.authenticate&&!a&&b.path("/login")})}),a.updateTableConfig=function(a,b){var c=_.find(a,{name:"All"});c&&(c.value=b)},i.defineRole("admin",[],function(){return h.isAdmin()})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics",{url:"/analytics",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("Extracted",["$resource",function(a){return a("/api/analytics/extracted/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.extracted",{url:"/extracted",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AnalyticExtractedListCtrl",["$scope","$translate","gridOptions","Extracted",function(a,b,c,d){a.moment=moment,a.Extracted=d,a.initView=function(){var b={exporterCsvFilename:"ExtractedReports.csv",columnDefs:[{name:"name"},{name:"startDate",displayName:"APPLICATION_START_DATE"},{name:"endDate",displayName:"APPLICATION_END_DATE"},{name:"createdAt",displayName:"APPLICATION_RUN_DATE"},{name:"startDate",displayName:"APPLICATION_START_DATE"},{name:"output"},{name:"status"},{name:"action",width:140,buttons:[{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"},{directive:""}]}]};a.gridOptions=c.gridOptions(d,b,a,{order:"createdAt DESC"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.extracted.list",{url:"/list",templateUrl:"app/analytic/extracted/list/list.html",controller:"AnalyticExtractedListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("AnalyticMetricListCreateModalCtrl",["$scope","$uibModalInstance",function(a,b){a.forms={dashboard:void 0},a.item={},a.tables=[{name:"Agent Report",value:"report_agent_history"},{name:"Mail Report",value:"report_mail_session_history"},{name:"Queue Report",value:"report_queue_history"},{name:"Integration Report",value:"report_integration_history"},{name:"Chat Report",value:"report_chat_session_history"}],a.ok=function(){a.item.model=JSON.stringify({title:a.item.name}),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("AnalyticMetricListCtrl",["$scope","xAlert","Modal","$uibModal","$log","gridOptions","Metric","$translate",function(a,b,c,d,e,f,g,h){a.$translate=h,a.initView=function(){var b={exporterCsvFilename:"Metrics.csv",columnDefs:[{name:"name"},{name:"table",cellTemplate:"
{{'APPLICATION_'+row.entity.table.toUpperCase() | translate}}
"},{name:"description"},{name:"action",width:125,buttons:[{"class":"{{row.entity.defaultEntry ? 'blue-hoki disabled' : 'blue-hoki'}}",href:"/analytics/metrics/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=f.gridOptions(g,b,a)},a.create=function(){var c=d.open({animation:!0,templateUrl:"app/analytic/metric/list/create.modal.html",controller:"AnalyticMetricListCreateModalCtrl"});c.result.then(function(c){return g.save(c).$promise.then(function(){a.gridOptions.getPage(),b.show(h.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(a.data.message,"danger")})},function(){e.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.metrics.list",{url:"/list",templateUrl:"app/analytic/metric/list/list.html",controller:"AnalyticMetricListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Metric",["$resource",function(a){return a("/api/analytics/metrics/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.metrics",{url:"/metrics",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AnalyticMetricViewCtrl",["$scope","xAlert","$translate","$stateParams","$location","Metric",function(a,b,c,d,e,f){a.tables=[{name:"Agent Report",value:"report_agent_history"},{name:"Mail Report",value:"report_mail_session_history"},{name:"Queue Report",value:"report_queue_history"},{name:"Integration Report",value:"report_integration_history"},{name:"Chat Report",value:"report_chat_session_history"}],a.getMetric=function(){return f.get({id:d.id}).$promise.then(function(b){a.metric=b})["catch"](function(a){e.path("/analytics/metrics/list")})},a.updateMetric=function(){return f.update({id:d.id},a.metric).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.metrics.view",{url:"/view/:id",templateUrl:"app/analytic/metric/view/view.html",controller:"AnalyticMetricViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.analytics.metrics.view.settings",{url:"/settings",templateUrl:"app/analytic/metric/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("customReport",["$resource",function(a){return a("/api/analytics/reports/custom/:id/:controller/:action",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("defaultReport",["$resource",function(a){return a("/api/analytics/reports/default/:id/:controller/:action",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("ReportListCopyModalCtrl",["$scope","$uibModalInstance","$log","customTreeData",function(a,b,c,d){a.customTreeData=d,a.forms={dashboard:void 0},a.item={},a.customTreeConfig={multiple:!1,animation:!0,core:{error:function(a){c.error("treeCtrl: error from js tree - "+angular.toJson(a))},check_callback:!0}},a.ac=function(){return!0},a.initCustomScopeTree=function(){a.customTree=a.customTreeInstance.jstree(!0),a.customTree.deselect_all(),a.customTree.open_all()},a.ok=function(){b.close({parent:a.customTree.get_selected(!0).pop().id})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ReportListCreateModalCtrl",["$scope","$uibModalInstance","path",function(a,b,c){a.path=c,a.forms={dashboard:void 0},a.item={},a.ok=function(){a.item.model=JSON.stringify({title:a.item.name}),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ReportListExtractModalCtrl",["$scope","$uibModalInstance",function(a,b){a.dates={startDate:moment().subtract(1,"days").startOf("day"),endDate:moment().subtract(1,"days").endOf("day")},a.ranges={Yesterday:[moment().subtract(1,"days").startOf("day"),moment().subtract(1,"days").endOf("day")],"Last 7 days":[moment().subtract(7,"days"),moment()],"Last 30 days":[moment().subtract(30,"days"),moment()],"This month":[moment().startOf("month"),moment().endOf("month")]},a.extract=function(c){var d={startDate:a.dates.startDate.toISOString(),endDate:a.dates.endDate.toISOString(),output:c};b.close(d)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("AnalyticReportListCtrl",["$scope","xAlert","$translate","$location","$log","Modal","$uibModal","FileSaver","Blob","gridOptions","customReport","defaultReport","reportTree",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){var b,c={},d=a.defaultTree.get_selected(),e=a.customTree.get_selected();if(d.length)b=d.pop(),a.selectedNode=a.defaultTree.get_path(b," / "),c={parent:b},a.gridOptions=j.gridOptions(l,o,a,c,!0),a.gridOptions.getPage();else{if(!e.length)return;b=e.pop(),a.selectedNode=a.customTree.get_path(b," / "),c={parent:b},a.gridOptions=j.gridOptions(k,o,a,c,!0),a.gridOptions.getPage()}}var o={exporterCsvFilename:"reports.csv",columnDefs:[{name:"name"},{name:"description"},{name:"manage",width:120,buttons:[{"class":"blue-hoki",href:"/analytics/reports/view/{{row.entity.id}}/settings",icon:"icon-settings",title:c.instant("APPLICATION_SETTINGS")},{"class":"red-sunglo",icon:"fa fa-trash-o",title:c.instant("APPLICATION_DELETE"),onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"},{"class":"green",icon:"fa fa-files-o",title:c.instant("APPLICATION_COPY"),onClick:"grid.appScope.copy(row.entity.id)"},{"class":"purple",icon:"fa fa-download",title:c.instant("APPLICATION_EXPORT"),onClick:"grid.appScope.export(row.entity.id)"}]},{name:"actions",buttons:[{"class":"yellow",name:"preview",onClick:"grid.appScope.preview(row.entity.id)"},{"class":"green-turquoise",name:"run",onClick:"grid.appScope.extract(row.entity.id)"}]}]};a.searchField="",a.ac=function(){return!0},a.initDefaultScopeTree=function(){a.defaultTree=a.defaultTreeInstance.jstree(!0),a.defaultTree.deselect_all(),a.defaultTree.close_all(),a.defaultTree.open_node({id:1}),a.defaultTreeReady=!0,a.defaultTreeActive=!0,a.previousDefaultNode=""},a.initCustomScopeTree=function(){a.customTree=a.customTreeInstance.jstree(!0),a.customTree.deselect_all(),a.customTree.close_all(),a.customTree.open_node({id:1}),a.customTreeReady=!0,a.previousCustomNode=""},a.$watchGroup(["defaultTreeReady","customTreeReady"],function(b,c,d){b[0]&&b[1]&&a.defaultTree.select_node({id:"1"})}),a.updateCustomTree=function(){var d={tree:angular.toJson(a.customTree.get_json("#",{flat:!0}))};return m.update({id:2},d).$promise.then(function(a){console.log("Custom Tree Updated")})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.configTrees=function(){a.defaultTreeConfig={multiple:!1,animation:!0,core:{error:function(a){e.error("treeCtrl: error from js tree - "+angular.toJson(a))},check_callback:!0,themes:{name:"default",url:"../../../assets/css/jstree-metronic/style.css"}},plugins:["search"]},a.customTreeConfig={multiple:!1,animation:!0,core:{error:function(a){e.error("treeCtrl: error from js tree - "+angular.toJson(a))},check_callback:!0,themes:{name:"default",url:"../../../assets/css/jstree-metronic/style.css"}},plugins:["contextmenu","dnd","search"],contextmenu:{items:function(b,d){var e={create:{label:c.instant("APPLICATION_CREATE"),action:function(c){a.customTree.create_node(b),a.customTree.open_node(b)}},rename:{label:c.instant("APPLICATION_RENAME"),action:function(c){a.customTree.edit(b)}},remove:{label:c.instant("APPLICATION_REMOVE"),action:function(c){console.log(b),a.deleteNode(b.text,b)}}};return"#"===b.parent&&(delete e.rename,delete e.remove),d(e),e}}}},a.deleteNode=f.confirm["delete"](function(b){a.customTree.delete_node(b),a.previousCustomNode==b.id&&a.customTree.select_node({id:b.parent})}),a.searchTrees=function(){a.defaultTree.search(a.searchField),a.customTree.search(a.searchField)},a.selectDefaultNode=function(){if(a.customTreeReady){a.previousCustomNode="";var b=a.defaultTree.get_selected(!0),c=b.pop();if(a.defaultTree.deselect_node(b[0],!0),a.customTree.deselect_all(),a.defaultTree.select_node(c,!0),c.id===a.previousDefaultNode)return void console.log("def");a.previousDefaultNode=c.id,a.defaultTreeActive=!0,n()}},a.selectCustomNode=function(){if(a.defaultTreeReady){a.previousDefaultNode="";var b=a.customTree.get_selected(!0),c=b.pop();if(a.customTree.deselect_node(b[0],!0),a.defaultTree.deselect_all(),a.customTree.select_node(c,!0),c.id===a.previousCustomNode)return void console.log("cus");a.previousCustomNode=c.id,a.defaultTreeActive=!1,n()}},a.getTrees=function(){return m.query().$promise.then(function(b){a.defaultTreeData=JSON.parse(b[0].tree),a.customTreeData=JSON.parse(b[1].tree),a.configTrees()})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.create=function(){var c=g.open({animation:!0,templateUrl:"app/analytic/report/list/create.modal.html",controller:"ReportListCreateModalCtrl",resolve:{path:function(){return a.selectedNode}}});c.result.then(function(c){return c.parent=a.previousCustomNode,k.save(c).$promise.then(function(a){d.path("/analytics/reports/view/"+a.id+"/settings")})["catch"](function(a){b.show(a.message,"danger")})},function(){e.info("Modal dismissed at: "+new Date)})},a.copy=function(d){var f=a.defaultTreeActive?l:k,h=g.open({animation:!0,templateUrl:"app/analytic/report/list/copy.modal.html",controller:"ReportListCopyModalCtrl",resolve:{customTreeData:function(){return a.customTreeData}}});h.result.then(function(e){return f.save({id:d,controller:"copy"},e).$promise.then(function(){a.gridOptions.getPage(),b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message,"danger")})},function(){e.info("Modal dismissed at: "+new Date)})},a["export"]=function(c){var d=a.defaultTreeActive?l:k;return d.get({id:c}).$promise.then(function(a){delete a.id,delete a.createdAt,delete a.updatedAt,delete a.deletedAt,_.forEach(a.Fields,function(a){delete a.id,delete a.CustomReportId,a.Metric&&(delete a.Metric.id,a.Metric.name+="_"+_.random(9999))});var b=new i([angular.toJson(a)],{type:"application/json;charset=utf-8"});h.saveAs(b,a.name+".json")})["catch"](function(a){console.error(data),b.show(a.message,"danger")})},a["import"]=function(d){var e=JSON.parse(d);e.parent=a.previousCustomNode;var f=e.name&&e.parent?!0:!1,g=!0;return _.forEach(e.Fields,function(a){a.field&&a.alias||(g=!1)}),f&&g?k.save({controller:"import"},e).$promise.then(function(){a.gridOptions.getPage(),b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message,"danger")}):void b.show(c.instant("MESSAGE_INVALID_JSON"),"danger")},a.preview=function(b){g.open({animation:!0,templateUrl:"app/analytic/report/list/preview.modal.html",controller:"ReportListPreviewModalCtrl",size:"full",resolve:{report:function(){return{id:b,tree:a.defaultTreeActive?"default":"custom"}}}})},a.extract=function(d){var f=g.open({animation:!0,templateUrl:"app/analytic/report/list/extract.modal.html",controller:"ReportListExtractModalCtrl",size:"md",resolve:{report:function(){return{id:d,tree:a.defaultTreeActive?"default":"custom"}}}});f.result.then(function(e){var f=a.defaultTreeActive?l:k;return f.get({id:d,controller:"extract",action:e.output,startDate:e.startDate,endDate:e.endDate}).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message,"danger")})},function(){e.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.reports.list",{url:"/list",templateUrl:"app/analytic/report/list/list.html",controller:"AnalyticReportListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ReportListPreviewModalCtrl",["$scope","$uibModalInstance","report","xAlert","$translate","$timeout","customReport","defaultReport",function(a,b,c,d,e,f,g,h){a.forms={dashboard:void 0},a.dates={startDate:moment().subtract(1,"days").startOf("day"),endDate:moment().subtract(1,"days").endOf("day")},a.ranges={Yesterday:[moment().subtract(1,"days").startOf("day"),moment().subtract(1,"days").endOf("day")],"Last 7 days":[moment().subtract(7,"days"),moment()],"Last 30 days":[moment().subtract(30,"days"),moment()],"This month":[moment().startOf("month"),moment().endOf("month")]};var i={pageNumber:1,pageSize:25,sort:null,where:{},order:{}};a.gridOptions={paginationPageSizes:[10,25,50],paginationPageSize:25,useExternalPagination:!0,enableSorting:!1,enableFiltering:!0,useExternalFiltering:!0,enableGrouping:!1,enableColumnMenus:!1,treeRowHeaderAlwaysVisible:!1,gridMenuShowHideColumns:!1,enableGridMenu:!1,onRegisterApi:function(b){a.gridApi=b,b.pagination.on.paginationChanged(a,function(b,c){i.offset=(b-1)*c,i.limit=c,a.getPage()}),b.core.on.filterChanged(a,function(){var b=this.grid,c={};b.columns.forEach(function(a){console.log(a),a.filters[0].term&&(c[a.field]=a.filters[0].term)}),i.where=c,a.getPage()})}},a.getPage=function(){var b={params:{offset:i.offset,limit:i.limit,startDate:a.dates.startDate.toISOString(),endDate:a.dates.endDate.toISOString()}};_.forOwn(i.where,function(a,c){b.params[c]=a}),console.log(b);var f="custom"===c.tree?g:h;return f.get({id:c.id,controller:"preview"},b).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.paginationPageSizes[3]=b.count,a.gridOptions.data=b.rows,a.showResult=!0})["catch"](function(a){d.show(e.instant(a.message),"danger")})},a.cancel=function(){b.dismiss("cancel")},f(function(){a.getPage()})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.reports",{url:"/reports",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("reportTree",["$resource",function(a){return a("/api/analytics/reports/trees/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("AnalyticReportViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location",function(a,b,c,d,e,f){function g(e){var f=_.find(a.tables,{table:e}).url;b.get(f).success(function(b){a.tableFields=_.map(b,function(a,b){return{name:b,value:b}})}).error(function(a){c.show(d.instant(a.message),"danger")})}function h(e){console.log(e),b.get("/api/analytics/metrics/table",{params:{table:e}}).success(function(b){_.forEach(b,function(b){a.tableFields.push({name:"Metric."+b.name,value:b.metric,MetricId:b.id})})}).error(function(a){c.show(d.instant(a.message),"danger")})}function i(a){return String(a).replace(//g,">")}function j(a){if(!a)return"";for(var b="(",c=0;c0&&(b+=" "+a.operator+" "),b+=a.rules[c].group?j(a.rules[c].group):a.rules[c].field+" "+i(a.rules[c].condition)+" '"+("like"===a.rules[c].condition?"%"+a.rules[c].value+"%":a.rules[c].value)+"'";return b+")"}a.$translate=d,a.tempReport={},a.tables=[{name:"Agent Report",table:"report_agent_history",url:"/api/report/agents/describe"},{name:"Mail Report",table:"report_mail_session_history",url:"/api/report/mail/sessions/describe"},{name:"Queue Report",table:"report_queue_history",url:"/api/report/queues/describe"},{name:"Chat Report",table:"report_chat_session_history",url:"/api/report/chat/sessions/describe"}];var k={group:{operator:"AND",rules:[]}};a.getReport=function(){a.firstLoad=!0,b.get("/api/analytics/reports/custom/"+e.id).success(function(b){a.report=b,_.forEach(a.report.Fields,function(a){delete a.id}),a.report.conditions=a.report.conditions?JSON.parse(a.report.conditions):_.clone(k,!0),a.getPreview(a.report.Fields.length)}).error(function(a){console.error(a),f.path("/analytics/reports/list")})},a.randomName=function(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")},a.$watch("report.table",function(b,c){console.log(b),b&&(console.log("is newvalue"),g(b),h(b),c&&(console.log("is oldvalue"),a.tempReport[c]={conditions:a.report.conditions,fields:a.report.Fields}),a.firstLoad?a.firstLoad=!1:a.tempReport[b]?(a.report.Fields=a.tempReport[b].fields,a.report.conditions=a.tempReport[b].conditions):(a.report.Fields=[],a.report.conditions=_.clone(k,!0)))},!0),a.setMetricId=function(b,c){a.report.Fields[c].MetricId=b.MetricId?b.MetricId:null},a.groupByField=[{name:"APPLICATION_YES",value:!0},{name:"APPLICATION_NO",value:!1}],a.functions=[{name:"Sum",value:"SUM"},{name:"Count",value:"COUNT"},{name:"Count Distinct",value:"COUNT DISTINCT"},{name:"Maximum",value:"MAX"},{name:"Minimum",value:"MIN"},{name:"Average",value:"AVG"},{name:"Group Concat",value:"GROUP_CONCAT"},{name:"Group Concat(asc)",value:"GROUP_CONCAT ASC"},{name:"Group Concat(desc)",value:"GROUP_CONCAT DESC"}],a.addField=function(){a.report.Fields.push({groupBy:!1})},a.removeField=function(b){a.report.Fields.splice(b,1)},a.sortableOptions={"ui-floating":!0,cancel:".unsortable",handle:".report-field-handle",axis:"y"},a.updateReport=function(){if(a.report.Fields.length){var f=angular.copy(a.report);f.conditions=angular.toJson(f.conditions),b.put("/api/analytics/reports/custom/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success"),a.getPreview(!0)}).error(function(b){c.show(d.instant(b.message),"danger"),f.conditions=JSON.parse(f.conditions),a.report=f})}else c.show(d.instant("MESSAGE_SELECT_A_FIELD"),"danger")},a.$watch("report.conditions",function(b){a.output=b?j(b.group):"()"},!0),a.gridOptions={enableFiltering:!0,treeRowHeaderAlwaysVisible:!1,enableGridMenu:!0},a.getPreview=function(f){b.get("/api/analytics/reports/custom/"+e.id+"/preview/",{params:{limit:20}}).success(function(b){a.gridOptions.data=b.rows}).error(function(a){f&&c.show(d.instant(a.message||"MESSAGE_QUERY_NOT_VALID"),"warning")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.reports.view",{url:"/view/:id",templateUrl:"app/analytic/report/view/view.html",controller:"AnalyticReportViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.analytics.reports.view.settings",{url:"/settings",templateUrl:"app/analytic/report/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels",{url:"/channels",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat",{url:"/chat",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("ChatEnquiry",["$resource",function(a){return a("/api/chat/enquiries/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatMessage",["$resource",function(a){return a("/api/chat/messages/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatReport",["$resource",function(a){return a("/api/report/chats/:id/:controller1/:controller2",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatRoom",["$resource",function(a){return a("/api/chat/rooms/:id/:controller",{id:"@id"},{me:{method:"GET",isArray:!0,params:{id:"me"}},users:{method:"GET",params:{id:"users"}},externals:{method:"GET",isArray:!0,params:{id:"type",controller:"external"}},groups:{method:"GET",isArray:!0,params:{id:"groups"}},update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatVisitor",["$resource",function(a){return a("/api/chat/visitors/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("ChatOfflineListCtrl",["$scope","ChatVisitor","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"chat_offline_messages.csv",columnDefs:[{name:"fullname",cellClass:"text-center"},{name:"email",cellClass:"text-center"},{name:"ChatWebsite.name",displayName:"Website",cellClass:"text-center"},{name:"createdAt",displayName:"createdAt",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'},{name:"action",width:100,buttons:[{"class":"blue-hoki",href:"/channels/chat/offline/view/{{row.entity.id}}/detail",name:"detail"}]}]};a.gridOptions=c.gridOptions(b,d,a,{origin:"enquiry"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.offline.list",{url:"/list",templateUrl:"app/channels/chat/offline/list/list.html",controller:"ChatOfflineListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.offline",{url:"/offline",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatOfflineViewCtrl",["$scope","$stateParams","ChatVisitor",function(a,b,c){a.initView=function(){return c.get({id:b.id}).$promise.then(function(b){a.chatVisitor=b})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.offline.view",{url:"/view/:id",templateUrl:"app/channels/chat/offline/view/view.html",controller:"ChatOfflineViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.chat.offline.view.detail",{url:"/detail",templateUrl:"app/channels/chat/offline/view/view.detail.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/news.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("ChatOnlineListCtrl",["$scope","ChatRoom","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"chat_online_messages.csv",columnDefs:[{name:"ChatVisitor.fullname",displayName:"APPLICATION_FULLNAME",cellClass:"text-center"},{name:"ChatVisitor.email",displayName:"APPLICATION_EMAIL",cellClass:"text-center"},{name:"action",width:100,buttons:[{"class":"blue-hoki",href:"/channels/chat/online/view/{{row.entity.id}}/detail",name:"detail"}]}]};a.gridOptions=c.gridOptions(b,d,a,{type:"external"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.online.list",{url:"/list",templateUrl:"app/channels/chat/online/list/list.html",controller:"ChatOnlineListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.online",{url:"/online",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatOnlineViewCtrl",["$scope","$stateParams","ChatRoom",function(a,b,c){a.initView=function(){return a.config={autoHideScrollbar:!1,theme:"light",advanced:{updateOnContentResize:!0},setHeight:400,scrollInertia:0},c.get({id:b.id}).$promise.then(function(b){a.chatRoom=b})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.online.view",{url:"/view/:id",templateUrl:"app/channels/chat/online/view/view.html",controller:"ChatOnlineViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.chat.online.view.detail",{url:"/detail",templateUrl:"app/channels/chat/online/view/view.detail.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/news.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("PreviewCtrl",["$scope",function(a){a.message="Hello"}]),angular.module("xCallyShuttleApp").directive("preview",function(){return{templateUrl:"app/channels/chat/preview/preview.html",restrict:"EA",link:function(a,b,c){}}}),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("preview",{url:"/preview",templateUrl:"app/channels/chat/preview/preview.html",controller:"PreviewCtrl"})}]),angular.module("xCallyShuttleApp").factory("ChatQueue",["$resource",function(a){return a("/api/chat/queues/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("ChatQueueListCtrl",["$scope","ChatQueue","gridOptions","$uibModal",function(a,b,c,d){a.initView=function(){var d={exporterCsvFilename:"chat_queues.csv",columnDefs:[{name:"name"},{name:"description"},{name:"strategy"},{name:"timeout"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/chat/queues/view/{{row.entity.id}}/settings", +name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){var b=d.open({animation:!0,templateUrl:"app/channels/mail/queue/list/list.create.modal.html",controller:"ChatQueueListCreateCtrl"});b.result.then(function(){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("ChatQueueListCreateCtrl",["$scope","$uibModalInstance","$translate","xAlert","ChatQueue",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return e.save(a.item).$promise.then(function(a){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),b.close(a)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.queues.list",{url:"/list",templateUrl:"app/channels/chat/queue/list/list.html",controller:"ChatQueueListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.queues",{url:"/queues",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatQueueViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","ChatQueue","Team",function(a,b,c,d,e,f,g){var h=function(){return{select:function(b){return f.save({id:a.queue.id,controller:"agents"},{agents:b,penalty:a.queue.penalty}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})},deselect:function(b){return f["delete"]({id:a.queue.id,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})}}};a.getQueue=function(){b.get("/api/chat/queues/"+e.id).success(function(b){b.penalty=0,a.queue=b}).error(function(a){console.error(a)})},a.updateChatQueue=function(){var f=angular.copy(a.queue);b.put("/api/chat/queues/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(b){a.queue=f,b.errors.forEach(function(a){c.show(a.message,"danger")})})},a.getTeams=function(){return g.get().$promise.then(function(b){return a.teams=b.rows,f.query({id:e.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindChatQueue(a.teams,_.map(b,function(a){return{id:a.id,penalty:a.UserHasChatQueue.penalty}}),h)})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.queues.view",{url:"/view/:id",templateUrl:"app/channels/chat/queue/view/view.html",controller:"ChatQueueViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.chat.queues.view.settings",{url:"/settings",templateUrl:"app/channels/chat/queue/view/view.settings.html"}).state("main.channels.chat.queues.view.agents",{url:"/agents",templateUrl:"app/channels/chat/queue/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.realtime",{url:"/realtime",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewAgentCtrl",["$scope","$log","$uibModal","$translate","socket","xAlert","Agent","Pause","Action","ChatQueue","usSpinnerService","$q","uiGridConstants",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){return k.spin("spinner-grid"),g.get(s).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.data=[],b.rows.forEach(function(a){p(a)})})["catch"](function(a){f.show(a.message,"danger")})["finally"](function(){k.stop("spinner-grid")})}function o(){e.socket.on("agent:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.id,isAgent:!0});if(c){var d=a.gridOptions.data.indexOf(c);a.gridOptions.data[d].online=b.online,a.gridOptions.data[d].lastLoginAt=b.lastLoginAt,a.gridOptions.data[d].pause=b.chatPause,a.gridOptions.data[d].pauseType=b.pauseType,a.gridOptions.data[d].lastPauseAt=b.lastPauseAt,a.gridOptions.data[d].ipaddr=b.ipaddr,a.gridOptions.data[d].port=b.port,a.gridOptions.data[d].fullcontact=b.fullcontact,a.gridOptions.data[d].useragent=b.useragent,a.gridOptions.data[d].lastms=b.lastms,a.gridOptions.data[d].internal=b.internal,_.map(a.gridOptions.data,function(a){a.isAgent||a.agentId!==b.id||(a.online=b.online)})}}),e.socket.on("agent:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.id})}),e.socket.on("user_has_chat_queue:save",function(b){console.log("new queue",b);var c=_.find(a.gridOptions.data,{agentId:b.UserId,isAgent:!0}),d=a.gridOptions.data.indexOf(c);a.gridOptions.data.splice(d+1,0,{isAgent:!1,agentId:b.UserId,queue:b.queue,queueId:b.ChatQueueId,agent:b.membername,online:c.online})}),e.socket.on("user_has_chat_queue:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.UserId,queueId:b.ChatQueueId})})}function p(b){a.gridOptions.data.push({isAgent:!0,agentId:b.id,agent:b.name,online:b.online,lastLoginAt:b.lastLoginAt,lastPauseAt:b.lastPauseAt,pause:b.chatPause,pauseType:b.pauseType,ipaddr:b.ipaddr,port:b.port,fullcontact:b.fullcontact,useragent:b.useragent,lastms:b.lastms,internal:b.internal,$$treeLevel:0}),b.ChatQueues.forEach(function(c){a.gridOptions.data.push({isAgent:!1,agentId:b.id,queue:c.name,queueId:c.id,agent:b.name,online:b.online})})}function q(){return h.get().$promise.then(function(b){a.pauses=b.rows,e.syncUpdates("pause",a.pauses)})["catch"](function(a){f.show(a.message,"danger")})}function r(){return j.get().$promise.then(function(b){a.chatQueues=b.rows,e.syncUpdates("chat_queue",a.chatQueues)})["catch"](function(a){f.show(a.message,"danger")})}a.chatQueues=[];var s={offset:0,limit:10};a.moment=moment,a.initAgents=function(){a.gridOptions={enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,showTreeExpandNoChildren:!0,columnDefs:[{name:"name",displayName:"APPLICATION_AGENT",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.agent}} <{{row.entity.internal}}>
'},{name:"online",displayName:"APPLICATION_ONLINE",width:150,headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
({{hhours}}:{{mminutes}}:{{sseconds}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"ONLINE"},{value:"false",label:"OFFLINE"}]}},{name:"chatPause",width:300,displayName:"APPLICATION_PAUSE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{hhours}}:{{mminutes}}:{{sseconds}}({{row.entity.pauseType}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"PAUSED"},{value:"false",label:"NOT PAUSED"}]},enableSorting:!1,enableColumnMenu:!1},{name:"queue",displayName:"APPLICATION_QUEUE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",displayName:"",width:170,cellClass:"text-center ui-grid-vcenter",cellTemplate:'
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1}],data:[],gridMenuTitleFilter:function(a){var b=l.defer();return b.resolve(d.instant(a)),b.promise},onRegisterApi:function(b){a.gridApi=b,a.gridApi.grid.registerDataChangeCallback(function(){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length)}),a.gridApi.treeBase.on.rowExpanded(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length+b.treeNode.children.length)}),a.gridApi.treeBase.on.rowCollapsed(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length-b.treeNode.children.length)}),a.gridApi.core.on.sortChanged(a,function(a,b){0===b.length?s.order=null:s.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),n()}),a.gridApi.pagination.on.paginationChanged(a,function(a,b){s.offset=(a-1)*b,s.limit=b,n()}),a.gridApi.core.on.filterChanged(a,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?s[a.name]=a.filters[0].term:delete s[a.name]}),n()})}},n(),q(),r(),o()};var t=function(a){var b=a?30*a+130:270;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px"),angular.element(document.getElementsByClassName("ui-grid-viewport")).css("height",30*a+"px")};a.$on("$destroy",function(){e.unsyncUpdates("agent"),e.unsyncUpdates("user_has_chat_queue")}),a.pause=function(a,b,c){return i.save({name:b,agent:a,type:c||"DEFAULT PAUSE",data4:c||"DEFAULT PAUSE",channel:"chat"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.joinQueue=function(e){var g=c.open({animation:!0,templateUrl:"app/channels/chat/realtime/view/agent/queue.modal.add.html",controller:"ChatRealtimeViewAgentQueueModalCtrl",resolve:{queues:function(){return _.reject(a.chatQueues,function(b){return _.find(a.gridOptions.data,{queue:b.name,isAgent:!1,agentId:e})?!0:!1})}}});g.result.then(function(b){return i.save({name:"QueueAdd",agent:e,queues:_.filter(a.chatQueues,function(a){return _.includes(b.queues,a.id)}),channel:"chat",data1:e,data3:b.queues.join(","),data4:"chat"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},function(){b.info("Modal dismissed at: "+new Date)})},a.leaveQueue=function(a,b){return i.save({name:"QueueRemove",agent:a,queueId:b,channel:"chat",data1:a,data3:b,data4:"chat"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.showInfo=function(a){c.open({animation:!0,templateUrl:"app/channels/chat/realtime/view/agent/agent.modal.info.html",controller:"ChatRealtimeViewAgentInfoModalCtrl",resolve:{agent:a}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.realtime.view.agents",{url:"/agents",templateUrl:"app/channels/chat/realtime/view/agent/agent.html",controller:"ChatRealtimeViewAgentCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewAgentInfoModalCtrl",["$scope","$uibModalInstance","$http","agent",function(a,b,c,d){a.agent=d,a.close=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewAgentQueueModalCtrl",["$scope","$uibModalInstance","$http","queues",function(a,b,c,d){a.queues=d,a.item={},a.save=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewQueueCtrl",["$scope","$http","socket","ChatQueue","Agent",function(a,b,c,d,e){a.initQueues=function(){a.gridOptions={enableSorting:!1,enableFiltering:!0,enableHorizontalScrollbar:0,enableVerticalScrollbar:0,showTreeExpandNoChildren:!1,columnDefs:[{name:"queueName",displayName:"Queue"},{name:"fullname",displayName:"Agent",cellClass:"text-center"},{name:"online",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'},{name:"chatPause",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
"},{name:"pauseType",cellClass:"text-center",cellTemplate:'{{row.entity.pauseType}}'},{name:"lastLoginAt",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'}],onRegisterApi:function(b){a.gridApi=b,a.gridApi.treeBase.on.rowExpanded(a,function(b){var c=_.findIndex(a.gridOptions.data,{$$hashKey:b.entity.$$hashKey});b.entity.Users&&b.entity.Users.forEach(function(b){_.find(a.gridOptions.data,{name:b.name})||a.gridOptions.data.splice(c+1,0,b)})})}},d.get(function(b){a.gridOptions.data=[],b.rows.forEach(function(b){b.$$treeLevel=0,b.queueName=b.name,a.gridOptions.data.push(b),b.Users&&b.Users.forEach(function(b){b.agentName=b.name,a.gridOptions.data.push(b)})}),c.socket.on("agent:save",function(b){var c=_.filter(a.gridOptions.data,{agentName:b.name});c.forEach(function(a){a.online=b.online,a.lastLoginAt=b.lastLoginAt})}),c.socket.on("chat_queue:save",function(b){b.$$treeLevel=0,b.queueName=b.name,a.gridOptions.data.push(b)}),c.socket.on("chat_queue:remove",function(b){_.remov(a.gridOptions.data,{queueName:b.name})}),c.socket.on("user_has_chat_queue:save",function(b){var c=_.findIndex(a.gridOptions.data,function(a){return a.queueName&&a.id===b.ChatQueueId});e.get({id:b.UserId}).$promise.then(function(b){a.gridOptions.data.splice(c+1,0,{id:b.id,name:b.name,fullname:b.fullname,agentName:b.name,online:b.online,lastLoginAt:b.lastLoginAt})})["catch"](function(a){console.error(a)})}),c.socket.on("user_has_chat_queue:remove",function(b){for(var c=_.findIndex(a.gridOptions.data,function(a){return a.queueName&&a.id===b.ChatQueueId}),d=c+1;dApril 1, 2014',sort:{direction:d.DESC,priority:1}},{name:"leaveAt",cellClass:"text-center",cellTemplate:''},{name:"unmanagedAt",cellClass:"text-center",cellTemplate:''}],data:[]},b.get("/api/report/chat/sessions").success(function(b){a.gridOptions.data=b.rows,c.socket.on("report_chat_session:save",function(b){var c=_.find(a.gridOptions.data,{id:b.id}),d=a.gridOptions.data.indexOf(c);c?_.merge(a.gridOptions.data[d],b):a.gridOptions.data.unshift(b)})}).error(function(a){console.error(a)})},a.$on("$destroy",function(){c.unsyncUpdates("report_chat:save"),c.unsyncUpdates("report_chat:update")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.realtime.view.sessions",{url:"/sessions",templateUrl:"app/channels/chat/realtime/view/session/session.html",controller:"ChatRealtimeViewSessionCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewCtrl",["$scope",function(a){a.agents=[{name:"Queues",link:"main.chat.realtime.view.agent.queues"},{name:"Timeline",link:"main.chat.realtime.view.agent.timeline"}],a.sessions=[{name:"Sessions",link:"main.chat.realtime.view.sessions"}]}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.realtime.view",{url:"/view",templateUrl:"app/channels/chat/realtime/view/view.html",controller:"ChatRealtimeViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatVisitorListCtrl",["$scope","ChatVisitor","gridOptions","$uibModal",function(a,b,c,d){a.initView=function(){var d={exporterCsvFilename:"chat_visitors.csv",columnDefs:[{name:"fullname",cellClass:"text-center"},{name:"email",cellClass:"text-center"},{name:"origin",cellClass:"text-center"},{name:"createdAt",displayName:"createdAt",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'},{name:"action",width:100,buttons:[{"class":"blue-hoki",href:"/channels/chat/visitors/view/{{row.entity.id}}/profile",name:"profile"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.visitors.list",{url:"/list",templateUrl:"app/channels/chat/visitor/list/list.html",controller:"ChatVisitorListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatVisitorViewCtrl",["$scope","$stateParams","ChatVisitor",function(a,b,c){a.initView=function(){return c.get({id:b.id}).$promise.then(function(b){a.chatVisitor=b})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.visitors.view",{url:"/view/:id",templateUrl:"app/channels/chat/visitor/view/view.html",controller:"ChatVisitorViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.chat.visitors.view.profile",{url:"/profile",templateUrl:"app/channels/chat/visitor/view/view.profile.html"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.visitors",{url:"/visitors",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("ChatApplication",["$resource",function(a){return a("/api/chat/applications/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatWebsite",["$resource",function(a){return a("/api/chat/websites/:websiteId/:controller/:id",{id:"@websiteId"},{update:{method:"PUT"},updateFields:{method:"PUT",isArray:!0}})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteListCtrl",["$scope","gridOptions","ChatWebsite",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"chat_websites.csv",columnDefs:[{name:"name"},{name:"description"},{name:"address"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/chat/websites/view/{{row.entity.id}}/embedding/view",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.list",{url:"/list",templateUrl:"app/channels/chat/website/list/list.html",controller:"ChatWebsiteListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.actions",{url:"/actions",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewActionListCtrl",["$scope","gridOptions","ChatWebsite","$http","$translate","$stateParams","socket","xAlert","Modal",function(a,b,c,d,e,f,g,h,i){a.initActons=function(){var d={draggable:!0,exporterCsvFilename:"chat_applications.csv",columnDefs:[{name:"app",cellClass:"text-center"},{name:"name",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.ChatQueue ? row.entity.ChatQueue.name : row.entity.User.name}}
"},{name:"timeout",cellClass:"text-center"},{name:"interval",cellClass:"text-center"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/chat/websites/view/{{row.entity.ChatWebsiteId}}/actions/view/{{row.entity.id}}",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.app, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a,{websiteId:f.websiteId,controller:"applications"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.actions.list",{url:"/list",templateUrl:"app/channels/chat/website/view/action/list/list.html",controller:"ChatWebsiteViewActionListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewActionViewCtrl",["$scope","$http","$stateParams","$translate","$location","xAlert","WizardHandler","socket","application","interval","ChatApplication","ChatQueue","Agent","Interval",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initAction=function(){return a.$application=i.application,a.$stateParams=c,a.$interval=j.interval,a.forms={},a.apps=[{name:"Queue",value:"queue"},{name:"Agent",value:"agent"}],k.get({id:c.actionId}).$promise.then(function(b){if(a.application=b,a.application.alwaysTime=!1,a.application.IntervalId)a.application.intType="list";else switch(a.application.interval){case"*,*,*,*":a.application.intType="always";break;default:a.application.intType="custom"}var c=a.application.interval.split(",");"*"===c[0]?a.application.alwaysTime=!0:(a.application.t_from=moment(new Date),a.application.t_to=moment(new Date),a.application.t_from.hour(c[0].split("-")[0].split(":")[0]),a.application.t_from.minute(c[0].split("-")[0].split(":")[1]),a.application.t_to.hour(c[0].split("-")[1].split(":")[0]),a.application.t_to.minute(c[0].split("-")[1].split(":")[1])),"*"===c[1]?(a.application.wd_from="always",a.application.wd_to="always"):(a.application.wd_from=c[1].split("-")[0],a.application.wd_to=c[1].split("-")[1]),"*"===c[2]?(a.application.md_from="always",a.application.md_to="always"):(a.application.md_from=c[2].split("-")[0],a.application.md_to=c[2].split("-")[1]),"*"===c[3]?(a.application.m_from="always",a.application.m_to="always"):(a.application.m_from=c[3].split("-")[0],a.application.m_to=c[3].split("-")[1]),a.$watch("application.t_from",function(b){a.application.t_from_hm=moment(b).format("HH:mm")}),a.$watch("application.t_to",function(b){a.application.t_to_hm=moment(b).format("HH:mm")})})["catch"](function(a){f.show(d.instant("Something went wrong!"),"danger")})},a.getQueues=function(){return l.get().$promise.then(function(b){a.queues=b.rows})["catch"](function(a){console.error(a)})},a.getAgents=function(){return m.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)})},a.getIntervals=function(){return n.get().$promise.then(function(b){a.intervals=b.rows})["catch"](function(a){console.error(a)})},a.updateItem=function(){var b=["*","*","*","*"],e={app:a.application.app,timeout:a.application.timeout,chatAccountId:c.id};switch(a.application.app){case"agent":e.UserId=a.application.UserId;break;case"queue":e.chatQueueId=a.application.chatQueueId}switch(a.application.intType){case"always":e.interval=b.join(","),delete a.application.IntervalId;break;case"custom":a.application.alwaysTime||(b[0]=a.application.alwaysTime?"*":a.application.t_from_hm+"-"+a.application.t_to_hm),a.application.wd_from&&a.application.wd_to&&"always"===a.application.wd_from&&"always"===a.application.wd_to?b[1]="*":b[1]=a.application.wd_from&&a.application.wd_to?a.application.wd_from+"-"+a.application.wd_to:"*",a.application.md_from&&a.application.md_to&&"always"===a.application.md_from&&"always"===a.application.md_to?b[2]="*":b[2]=a.application.md_from&&a.application.md_to?a.application.md_from+"-"+a.application.md_to:"*",a.application.m_from&&a.application.m_to&&"always"===a.application.m_from&&"always"===a.application.m_to?b[3]="*":b[3]=a.application.m_from&&a.application.m_to?a.application.m_from+"-"+a.application.m_to:"*",e.interval=b.join(","),delete a.application.IntervalId;break;case"list":e.IntervalId=a.application.IntervalId}return k.update({id:c.actionId},e).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.actions.view",{url:"/view/:actionId",templateUrl:"app/channels/chat/website/view/action/view/view.html",controller:"ChatWebsiteViewActionViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewActionWizardCtrl",["$scope","$http","Agent","Interval","ChatQueue","$stateParams","$translate","$location","xAlert","WizardHandler","socket","application","interval",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initWizard=function(){a.apps=[{name:"Queue",value:"queue"},{name:"Agent",value:"agent"}],a.$application=l.application,a.$stateParams=f,a.$interval=m.interval,a.forms={},a.application={app:"queue",intType:"always",alwaysTime:!0},a.$watch("application.t_from",function(b){a.application.t_from_hm=moment(b).format("HH:mm")}),a.$watch("application.t_to",function(b){a.application.t_to_hm=moment(b).format("HH:mm")})},a.getQueues=function(){return e.get().$promise.then(function(b){a.queues=b.rows})["catch"](function(a){console.error(a)})},a.getAgents=function(){return c.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)})},a.getIntervals=function(){return d.get().$promise.then(function(b){a.intervals=b.rows})["catch"](function(a){console.error(a)})},a.createItem=function(){var c=["*","*","*","*"],d={app:a.application.app,timeout:a.application.timeout,ChatWebsiteId:f.websiteId};switch(a.application.app){case"agent":d.UserId=a.application.UserId;break;case"queue":d.ChatQueueId=a.application.ChatQueueId}switch(a.application.intType){case"always":d.interval=c.join(","),delete a.application.IntervalId;break;case"custom":a.application.alwaysTime||(c[0]=a.application.alwaysTime?"*":a.application.t_from_hm+"-"+a.application.t_to_hm),a.application.wd_from&&a.application.wd_to&&"always"===a.application.wd_from&&"always"===a.application.wd_to?c[1]="*":c[1]=a.application.wd_from&&a.application.wd_to?a.application.wd_from+"-"+a.application.wd_to:"*",a.application.md_from&&a.application.md_to&&"always"===a.application.md_from&&"always"===a.application.md_to?c[2]="*":c[2]=a.application.md_from&&a.application.md_to?a.application.md_from+"-"+a.application.md_to:"*",a.application.m_from&&a.application.m_to&&"always"===a.application.m_from&&"always"===a.application.m_to?c[3]="*":c[3]=a.application.m_from&&a.application.m_to?a.application.m_from+"-"+a.application.m_to:"*",d.interval=c.join(","),delete a.application.IntervalId;break;case"list":d.IntervalId=a.application.IntervalId}b.post("/api/chat/applications",d).success(function(){h.path("/channels/chat/websites/view/"+f.websiteId+"/actions/list")}).error(function(a){console.error(a)})},a.formValidation=function(a){return a},a.next=function(){j.wizard().next()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.actions.wizard",{url:"/wizard",templateUrl:"app/channels/chat/website/view/action/wizard/wizard.html",controller:"ChatWebsiteViewActionWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.embedding",{url:"/embedding",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewEmbeddingViewCtrl",["$scope","$stateParams","$translate","clipboard","xAlert","ChatWebsite",function(a,b,c,d,e,f){a.initView=function(){return f.get({websiteId:b.websiteId,controller:"snippet"}).$promise.then(function(b){a.snippetCode=b.html})["catch"](function(a){e.show(a.message,"danger")})},a.copyToClipboard=function(){d.copyText(a.snippetCode),e.show(c.instant("MESSAGE_TEXT_COPIED_CLIPBOARD")+"!","success")}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.embedding.view",{url:"/view",templateUrl:"app/channels/chat/website/view/embedding/view/view.html",controller:"ChatWebsiteViewEmbeddingViewCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.form",{url:"/forms",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewFormViewCtrl",["$scope","$builder","$validator","$stateParams","$translate","ChatWebsite","xAlert",function(a,b,c,d,e,f,g){ +a.saveForm=function(a){var c=angular.copy(b.forms[a]);return c.length>3?g.show("You can insert at least 3 input elements","danger"):(_.forEach(c,function(a){delete a.id}),f.updateFields({websiteId:d.websiteId,controller:"fields",id:a},c).$promise.then(function(){g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.message,"danger")}))},a.getChatWebsiteFields=function(a){return f.query({websiteId:d.websiteId,controller:"fields",id:a}).$promise.then(function(c){_.forEach(c,function(c){b.addFormObject(a,c)})})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.form.view",{url:"/view",templateUrl:"app/channels/chat/website/view/form/view/view.html",controller:"ChatWebsiteViewFormViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewProactiveListCtrl",["$scope","gridOptions","ChatWebsite","$http","$translate","$stateParams","$uibModal",function(a,b,c,d,e,f,g){a.initProactiveActions=function(){var d={exporterCsvFilename:"telephones.csv",columnDefs:[{name:"name"},{name:"type"},{name:"action",width:125,buttons:[{"class":"blue-hoki",onClick:"grid.appScope.createItem(row.entity)",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a,{websiteId:f.websiteId,controller:"proactive"})},a.createItem=function(b){var c=g.open({animation:!0,templateUrl:"app/channels/chat/website/view/proactive/list/list.create.modal.html",controller:"ChatWebsiteProactiveListCreateCtrl",resolve:{item:b}});c.result.then(function(b){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteProactiveListCreateCtrl",["$scope","$translate","$uibModalInstance","$stateParams","ChatWebsite","xAlert","item",function(a,b,c,d,e,f,g){a.form={},a.item=g||{},a.title=g?b.instant("APPLICATION_EDIT_PROACTIVE_ACTION"):b.instant("APPLICATION_NEW_PROACTIVE_ACTION"),a.possibleType=[{type:"mouseOver",title:"Mouse Over"},{type:"timeout",title:"Timeout"}],a.save=function(){return g?e.update({websiteId:d.websiteId,controller:"proactive",id:a.item.id},a.item).$promise.then(function(a){f.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){f.show(a.data.message,"danger")}):e.save({websiteId:d.websiteId,controller:"proactive"},a.item).$promise.then(function(a){f.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){f.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.proactive.list",{url:"/list",templateUrl:"app/channels/chat/website/view/proactive/list/list.html",controller:"ChatWebsiteViewProactiveListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.proactive",{url:"/proactive",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.snippet",{url:"/snippet",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewSnippetViewCtrl",["$scope","$http","$stateParams","$translate","Template",function(a,b,c,d,e){a.$translate=d,a.statePreview={state:"online"},a.enquirySwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.lang={HeaderCurrentlyChatting:"Live Chat",HeaderOffline:"Contact us",OperatorOfflineMessage:"It appears as if all operators are currently offline.",OfflineMessage:"We're not online.
It doesn't mean we're not there to help - leave your message below and we'll be in touch as soon as possible.",EnquiryMessagePlaceholder:"Your message...",EnquiryButtonText:"Leave message",EnquirySubmitSuccess:"Your message was sucessfully submitted - we will contact you as soon as possible.",OperatorComposing:"{fullname} is typing...",FirstMessageText:"",ExitChatButtonText:"Exit Chat",ExitChatQuestionText:"Are you sure?",ExitChatButtonConfirmText:"Yes",ExitChatButtonCancelText:"No",MessagePlaceholderText:"Your message...",MessageSendButtonText:"Send",ValidationEmailRequired:"Please enter your email address",ValidationEmailInvalid:"Please enter a valid email address",ValidationEmailMaxLength:"The email address may not exceed 85 characters",ValidationUsernameRequired:"Please enter your name",ValidationUsernameMaxLength:"The name may not exceed 45 characters",ValidationEnquiryRequired:"Please enter your enquiry",ValidationEnquiryMaxLength:"The enquiry may not exceed 1500 characters",ValidationMessageRequired:"Please enter your message",ValidationMessageMaxLength:"The message may not exceed 750 characters"},a.initView=function(){e.get().$promise.then(function(b){console.log(b),a.mailTemplates=b.rows})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.snippet.view",{url:"/view",templateUrl:"app/channels/chat/website/view/snippet/view/view.html",controller:"ChatWebsiteViewSnippetViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewCtrl",["$scope","xAlert","$http","$location","$stateParams","$translate","WizardHandler","ChatApplication","ChatWebsite",function(a,b,c,d,e,f,g,h,i){a.initApplication=function(){a.forms={},a.application={}},a.goNext=function(){g.wizard().next()},a.formValidation=function(a){return a},a.deleteItem=function(a){return h["delete"]({id:a}).$promise.then(function(){b.show(f.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(f.instant("Something went wrong!"),"danger")})},a.initView=function(){return i.get({id:e.websiteId}).$promise.then(function(b){a.chatWebsite=b})["catch"](function(a){b.show(a.message,"danger")})},a.updateItem=function(){return i.update({id:a.chatWebsite.id},a.chatWebsite).$promise.then(function(){b.show(f.instant("MESSAGE_CHAT_WEBSITE_UPDATE_SUCCESS")+"!","success")})["catch"](function(){b.show(f.instant("MESSAGE_CHAT_WEBSITE_UPDATE_FAILURE"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view",{url:"/view/:websiteId",templateUrl:"app/channels/chat/website/view/view.html",controller:"ChatWebsiteViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites",{url:"/websites",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteWizardCtrl",["$scope","$http","$location","$translate","WizardHandler","xAlert","ChatWebsite",function(a,b,c,d,e,f,g){a.$translate=d,a.forms={formSetting:void 0,formAppearance:void 0,formLabel:void 0,formFunctionality:void 0},a.next=function(){e.wizard().next()},a.exitValidation=function(a){return a},a.item={},a.createItem=function(){return g.save(a.item).$promise.then(function(){f.show(d.instant("MESSAGE_CHAT_WEBSITE_CREATE_SUCCESS"),"success"),c.path("/channels/chat/websites/list")})["catch"](function(a){f.show(d.instant("MESSAGE_CHAT_WEBSITE_CREATE_FAILURE"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.wizard",{url:"/wizard",templateUrl:"app/channels/chat/website/wizard/wizard.html",controller:"ChatWebsiteWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.accounts",{url:"/accounts",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("FaxAccountListCtrl",["$scope","$http","xAlert","$translate","socket","Modal","$rootScope","$log","stResource",function(a,b,c,d,e,f,g,h,i){a.conf={faxAccountsByPage:{name:"10",value:10}},a.faxAccountsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.fax_accounts={checked:[]},a.check=function(b,c){c?a.fax_accounts.checked=angular.copy(_.map(a.displayedFaxAccounts,"id")):a.fax_accounts.checked=[]},a.initList=function(b){e.unsyncUpdates("fax_account"),b.url="/api/fax/accounts",i.getPage(b).then(function(c){a.displayedFaxAccounts=c.rows,b.pagination.numberOfPages=c.total_pages,g.updateTableConfig(a.faxAccountsByPage,a.displayedFaxAccounts.length),g.updateTableConfig(a.conf.faxAccountsByPage,a.displayedFaxAccounts.length)}),e.socket.on("fax_account:save",function(){a.initList(b)}),e.socket.on("fax_account:remove",function(c){a.fax_accounts.checked=_.without(a.fax_accounts.checked,c.id),a.initList(b)})},a.deleteItem=f.confirm["delete"](function(a){b["delete"]("api/fax/accounts/"+a).success(function(){c.show(d.instant("MESSAGE_FAX_ACCOUNT_DELETE_SUCCESS"),"success")}).error(function(){c.show(d.instant("MESSAGE_FAX_ACCOUNT_DELETE_FAILURE"),"danger")})}),a.deleteItems=f.confirm["delete"](function(){b["delete"]("/api/fax/accounts",{params:{id:a.fax_accounts.checked}}).success(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){c.show(d.instant(a.message),"danger")})}),a.getFaxAccounts=function(b){return _.map(a.faxAccountsByPage,function(a){var c={};return b.forEach(function(b){c[b]=a[b]}),c})},a.$on("$destroy",function(){e.unsyncUpdates("fax_account")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.accounts.list",{url:"/list",templateUrl:"app/channels/fax/account/list/list.html",controller:"FaxAccountListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("FaxAccountViewCtrl",["$scope","$http","$stateParams","$translate","$location","WizardHandler","socket","xAlert","Modal",function(a,b,c,d,e,f,g,h,i){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.forms={},a.sortableOptions={stop:function(){b.post("api/fax/accounts/"+c.id+"/applications",{applications:_.map(a.faxApplications,"id")}).success(function(b){a.faxApplications=b}).error(function(a){console.error(a)})},"ui-floating":!0},a.goNext=function(){f.wizard().next()},a.formValidation=function(a){return a},a.initApplication=function(){a.forms={},a.application={}},a.deleteItem=i.confirm["delete"](function(a){b["delete"]("api/fax/applications/"+a).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.getAppdata=function(b,c){switch(b){case"agent":return a.agents?_.find(a.agents,{id:c}).name:c;case"queue":return a.faxQueues?_.find(a.faxQueues,{id:c}).name:c}return"UNKNOWN"},a.createItem=function(){switch(a.application.appdata=a.application.appdata.id,a.application.app){case"agent":a.application.UserId=parseInt(a.application.appdata,10);break;case"queue":a.application.FaxQueueId=parseInt(a.application.appdata,10)}a.application.FaxAccountId=c.id,b.post("api/fax/applications",a.application).success(function(){e.path("/channels/fax/accounts/view/"+c.id+"/routes")}).error(function(){h.show("Something went wrong!","danger")})},a.$watch("application.app",function(c){if(c){var d;switch(c){case"agent":d="api/agents";break;case"queue":d="api/fax/queues"}b.get(d).success(function(b){a.items=b.rows})}},!0),a.initView=function(){b.get("/api/trunks").success(function(b){a.trunks=b.rows}).error(function(a){console.log(a)}),b.get("/api/fax/accounts/"+c.id).success(function(b){a.account=b}).error(function(){})},a.getAgents=function(){b.get("api/fax/agents").success(function(b){a.agents=b})},a.getFaxApplications=function(){b.get("/api/fax/applications",{params:{FaxAccountId:c.id}}).success(function(b){a.faxApplications=b,g.socket.on("fax_application:remove",function(b){_.remove(a.faxApplications,{id:b.id})})}),b.get("/api/agents").success(function(b){a.agents=b.rows}),b.get("/api/fax/queues").success(function(b){a.faxQueues=b.rows})},a.updateItemFaxAccount=function(){b.put("/api/fax/accounts/"+c.id,a.account).success(function(){h.show(d.instant("MESSAGE_FAX_ACCOUNT_UPDATE_SUCCESS")+".","success")}).error(function(){h.show(d.instant("MESSAGE_FAX_ACCOUNT_UPDATE_FAILURE")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.accounts.view",{url:"/view/:id",templateUrl:"app/channels/fax/account/view/view.html",controller:"FaxAccountViewCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]})}]}}).state("main.channels.fax.accounts.view.settings",{url:"/settings",templateUrl:"app/channels/fax/account/view/view.settings.html",authenticate:!0}).state("main.channels.fax.accounts.view.routes",{url:"/routes",templateUrl:"app/channels/fax/account/view/view.routes.html",authenticate:!0}).state("main.channels.fax.accounts.view.applications",{url:"/applications",templateUrl:"app/channels/fax/account/view/view.applications.html",authenticate:!0})}]),angular.module("xCallyShuttleApp").controller("FaxAccountWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initWizard=function(){a.$translate=d,a.forms={},a.item={},a.item.ecm=!1,a.item.minrate="9600",a.item.maxrate="33600",b.get("/api/trunks").success(function(b){a.trunks=b.rows}).error(function(a){console.error(a)})},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){b.post("api/fax/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_FAX_ACCOUNT_CREATE_SUCCESS")+".","success"),c.path("/channels/fax/accounts/list")}).error(function(){e.show(d.instant("MESSAGE_FAX_ACCOUNT_CREATE_FAILURE")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.accounts.wizard",{url:"/wizard",templateUrl:"app/channels/fax/account/wizard/wizard.html",controller:"FaxAccountWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax",{url:"/fax",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("FaxInboxComposeCtrl",["$scope","$http","FileUploader","$location","Auth","xAlert","$cookieStore","$translate",function(a,b,c,d,e,f,g,h){a.forms={},a.form={to:[],sto:[]},b.get("api/fax/accounts").success(function(b){a.faxAccounts=b.rows}),a.isNewMessageFromEmpty=!0;var i=a.uploader=new c({url:"api/fax/messages",queueLimit:1,withCredentials:!0,headers:{Authorization:"Bearer "+g.get("token")}});i.filters.push({name:"pdfFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|pdf|".indexOf(b)}}),i.onBeforeUploadItem=function(b){b.formData.push({accountId:a.form.from.id,toNum:a.form.sto[0],isNewRoom:a.isNewMessageFromEmpty,userId:e.getCurrentUser().id,html:a.form.html?a.form.html:""})},i.onSuccessItem=function(a,b,c,d){console.info("onSuccessItem",a,b,c,d)},i.onErrorItem=function(a,b,c,d){console.info("onErrorItem",a,b,c,d)},i.onCompleteAll=function(){i.clearQueue(),f.show(h.instant("MESSAGE_WELL_DONE"),"success"),d.path("/channels/fax/inbox/incoming")},i.onWhenAddingFileFailed=function(){f.show(h.instant("MESSAGE_WRONG_FORMAT"),"danger")},a.sendFax=function(){return a.form.sto.length?void(i.queue.length?i.uploadAll():b.post("api/fax/messages",{accountId:a.form.from.id,toNum:a.form.sto[0],isNewRoom:a.isNewMessageFromEmpty,userId:e.getCurrentUser().id,html:a.form.html,onlyText:!0}).success(function(){f.show(h.instant("MESSAGE_WELL_DONE"),"success"),d.path("/channels/fax/inbox/incoming")}).error(function(a){f.show(h.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger"),console.error(a)})):(a.forms.compose.to.$valid=!1,void(a.forms.compose.to.$invalid=!0))},a.cancel=function(){a.form.sto=[],delete a.form.from}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.inbox.compose",{url:"/compose",templateUrl:"app/channels/fax/inbox/room/room.html",controller:"FaxInboxComposeCtrl"})}]),angular.module("xCallyShuttleApp").controller("FaxInboxCtrl",["$scope","$http","$location","$translate","$timeout","$notification","Auth","socket","$interval",function(a,b,c,d,e,f,g,h,i){a.go=function(a,d,e){e?b.put("/api/fax/rooms/"+d,{status:e}).success(function(){c.path(a)}).error(function(a){console.error(a)}):c.path(a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.inbox",{url:"/inbox",templateUrl:"app/channels/fax/inbox/inbox.html",controller:"FaxInboxCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/inbox.css","assets/css/todo.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("FaxInboxIncomingCtrl",["$scope","$http","$location","socket","Auth","xAlert",function(a,b,c,d,e,f){a.$location=c,a.getRooms=function(){e.isAdmin()?b.get("api/fax/rooms").success(function(b){a.faxRooms=b,d.syncUpdates("fax_room",a.faxRooms)}).error(function(a){console.error(a),f.show($translate.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")}):b.get("api/fax/rooms/agent/"+e.getCurrentUser().id).success(function(b){a.faxRooms=b,d.socket.on("fax_room:update",function(b){b.UserId===e.getCurrentUser().id&&a.faxRooms.push(b)})}).error(function(a){f.show($translate.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger"),console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.inbox.incoming",{url:"/incoming",templateUrl:"app/channels/fax/inbox/incoming/incoming.html",controller:"FaxInboxIncomingCtrl"})}]),angular.module("xCallyShuttleApp").controller("FaxInboxRoomCtrl",["$scope","$http","$stateParams","$location","FileUploader","socket","Auth","xAlert","$translate","$cookieStore",function(a,b,c,d,e,f,g,h,i,j){function k(){a.lastMessage=_.reject(a.faxRoom.FaxMessages,function(a){return"RECEIVED"!==a.status}),a.lastMessage=_.sortByOrder(a.lastMessage,["id"],["desc"])[0],a.lastMessage&&(console.log(a.faxRoom),a.form.from=a.faxRoom.FaxAccount,a.form.to=[a.lastMessage.From.phone],a.form.sto=[a.lastMessage.From.phone])}var l=a.uploader=new e({url:"api/fax/messages",queueLimit:1,withCredentials:!0,headers:{Authorization:"Bearer "+j.get("token")}});l.filters.push({name:"pdfFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|pdf|".indexOf(b)}}),l.onBeforeUploadItem=function(b){console.log(a.form.from.id,a.form.sto[0],a.isNewMessageFromEmpty,c.id,g.getCurrentUser().id),b.formData.push({accountId:a.form.from.id,toNum:a.form.sto[0],isNewRoom:a.isNewMessageFromEmpty,roomId:c.id,userId:g.getCurrentUser().id,html:a.form.html}),console.log(b)},l.onSuccessItem=function(a,b,c,d){console.info("onSuccessItem",a,b,c,d)},l.onErrorItem=function(a,b,c,d){console.info("onErrorItem",b,c,d)},l.onCompleteAll=function(){l.clearQueue(),h.show(i.instant("MESSAGE_WELL_DONE"),"success")},l.onWhenAddingFileFailed=function(){h.show(i.instant("MESSAGE_WRONG_FORMAT"),"danger")},a.initRoomView=function(){a.isNewMessageFromEmpty=!0,a.Auth=g,a.forms={},a.form={to:[],sto:[]},b.get("api/agents").success(function(b){a.agents=b}),b.get("api/fax/accounts").success(function(b){a.faxAccounts=b.rows}),c.id&&b.get("/api/fax/rooms/"+c.id).success(function(b){a.faxRoom=b,a.isNewMessageFromEmpty=!1,f.syncUpdates("fax_message",[],function(b,c){"created"===b&&c.FaxRoomId===a.faxRoom.id&&(a.faxRoom.FaxMessages.push(c),k())}),k()}).error(function(a){console.error(a),h.show(i.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.sendFax=function(){return a.form.sto.length?void(l.queue.length?l.uploadAll():b.post("api/fax/messages",{accountId:a.form.from.id,toNum:a.form.sto[0],isNewRoom:a.isNewMessageFromEmpty,userId:g.getCurrentUser().id,html:a.form.html,onlyText:!0}).success(function(){h.show(i.instant("MESSAGE_WELL_DONE"),"success"),console.log("Fax Message sent")}).error(function(a){h.show(i.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger"),console.error(a)})):(a.forms.compose.to.$valid=!1,void(a.forms.compose.to.$invalid=!0))},a.assignAgent=function(a){b.put("/api/fax/rooms/"+c.id,{UserId:a}).success(function(){h.show(i.instant("MESSAGE_WELL_DONE"),"danger")}).error(function(){h.show(i.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.updateStatus=function(d){b.put("/api/fax/rooms/"+c.id,{status:d}).success(function(b){a.faxRoom.status=b.status,h.show(i.instant("MESSAGE_WELL_DONE"),"danger")}).error(function(a){console.error(a),h.show(i.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.cancel=function(){a.form.sto=[],delete a.form.from,l.clearQueue()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.inbox.room",{url:"/room/:id",templateUrl:"app/channels/fax/inbox/room/room.html",controller:"FaxInboxRoomCtrl"})}]),angular.module("xCallyShuttleApp").factory("FaxQueue",["$resource",function(a){return a("/api/fax/queues/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("FaxQueueListCtrl",["$scope","FaxQueue","gridOptions","$uibModal",function(a,b,c,d){a.initView=function(){var d={exporterCsvFilename:"fax_queues.csv",columnDefs:[{name:"name"},{name:"description"},{name:"strategy"},{name:"timeout"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/fax/queues/view/{{row.entity.id}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){var b=d.open({animation:!0,templateUrl:"app/channels/fax/queue/list/list.create.modal.html",controller:"FaxQueueListCreateCtrl"});b.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("FaxQueueListCreateCtrl",["$scope","$uibModalInstance","$translate","xAlert","FaxQueue",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return e.save(a.item).$promise.then(function(a){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),b.close(a)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.queues.list",{url:"/list",templateUrl:"app/channels/fax/queue/list/list.html",controller:"FaxQueueListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.queues",{url:"/queues",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("FaxQueueViewCtrl",["$scope","$http","$translate","$stateParams","xAlert","FaxQueue","Team",function(a,b,c,d,e,f,g){var h=function(){return{select:function(b){return f.save({id:a.queue.id,controller:"agents"},{agents:b,penalty:a.queue.penalty}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.error(a)})},deselect:function(b){return f["delete"]({id:a.queue.id,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.error(a)})}}};a.getQueue=function(){return f.get({id:d.id}).$promise.then(function(b){b.penalty=0,a.queue=b})["catch"](function(a){e.show(a.message,"danger")})},a.updateFaxQueue=function(){return f.update({id:d.id},{name:a.queue.name,description:a.queue.description,timeout:a.queue.timeout,strategy:a.queue.strategy}).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.message,"danger")})},a.getTeams=function(){return g.get().$promise.then(function(b){return a.teams=b.rows,f.query({id:d.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindMailQueue(a.teams,_.map(b,function(a){return{id:a.id,penalty:a.UserHasFaxQueue.penalty}}),h)})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.queues.view",{url:"/view/:id",templateUrl:"app/channels/fax/queue/view/view.html",controller:"FaxQueueViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.fax.queues.view.settings",{url:"/settings",templateUrl:"app/channels/fax/queue/view/view.settings.html"}).state("main.channels.fax.queues.view.agents",{url:"/agents",templateUrl:"app/channels/fax/queue/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.realtime",{url:"/realtime",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("FaxRealtimeViewAgentCtrl",["$scope","$log","$uibModal","$translate","socket","xAlert","Agent","Pause","Action","FaxQueue","usSpinnerService","$q","uiGridConstants",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){return k.spin("spinner-grid"),g.get(s).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.data=[],b.rows.forEach(function(a){p(a)})})["catch"](function(a){f.show(a.message,"danger")})["finally"](function(){k.stop("spinner-grid")})}function o(){e.socket.on("agent:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.id,isAgent:!0});if(c){var d=a.gridOptions.data.indexOf(c);a.gridOptions.data[d].online=b.online,a.gridOptions.data[d].lastLoginAt=b.lastLoginAt,a.gridOptions.data[d].pause=b.faxPause,a.gridOptions.data[d].pauseType=b.pauseType,a.gridOptions.data[d].lastPauseAt=b.lastPauseAt,a.gridOptions.data[d].ipaddr=b.ipaddr,a.gridOptions.data[d].port=b.port,a.gridOptions.data[d].fullcontact=b.fullcontact,a.gridOptions.data[d].useragent=b.useragent,a.gridOptions.data[d].lastms=b.lastms,a.gridOptions.data[d].internal=b.internal,_.map(a.gridOptions.data,function(a){a.isAgent||a.agentId!==b.id||(a.online=b.online)})}}),e.socket.on("agent:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.id})}),e.socket.on("user_has_fax_queue:save",function(b){console.log("new queue",b);var c=_.find(a.gridOptions.data,{agentId:b.UserId,isAgent:!0}),d=a.gridOptions.data.indexOf(c);a.gridOptions.data.splice(d+1,0,{isAgent:!1,agentId:b.UserId,queue:b.queue,queueId:b.FaxQueueId,agent:b.membername,online:c.online})}),e.socket.on("user_has_fax_queue:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.UserId,queueId:b.FaxQueueId})})}function p(b){a.gridOptions.data.push({isAgent:!0,agentId:b.id,agent:b.name,online:b.online,lastLoginAt:b.lastLoginAt,lastPauseAt:b.lastPauseAt,pause:b.faxPause,pauseType:b.pauseType,ipaddr:b.ipaddr,port:b.port,fullcontact:b.fullcontact,useragent:b.useragent,lastms:b.lastms,internal:b.internal,$$treeLevel:0}),b.FaxQueues.forEach(function(c){a.gridOptions.data.push({isAgent:!1,agentId:b.id,queue:c.name,queueId:c.id,agent:b.name,online:b.online})})}function q(){return h.get().$promise.then(function(b){a.pauses=b.rows,e.syncUpdates("pause",a.pauses)})["catch"](function(a){f.show(a.message,"danger")})}function r(){return j.get().$promise.then(function(b){a.faxQueues=b.rows,e.syncUpdates("fax_queue",a.faxQueues)})["catch"](function(a){f.show(a.message,"danger")})}a.faxQueues=[];var s={offset:0,limit:10};a.moment=moment,a.initAgents=function(){a.gridOptions={enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,showTreeExpandNoChildren:!0,columnDefs:[{name:"name",displayName:"APPLICATION_AGENT",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.agent}} <{{row.entity.internal}}>
'},{name:"online",displayName:"APPLICATION_ONLINE",width:150,headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
({{hhours}}:{{mminutes}}:{{sseconds}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"ONLINE"},{value:"false",label:"OFFLINE"}]}},{name:"faxPause",width:300,displayName:"APPLICATION_PAUSE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{hhours}}:{{mminutes}}:{{sseconds}}({{row.entity.pauseType}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"PAUSED"},{value:"false",label:"NOT PAUSED"}]},enableSorting:!1,enableColumnMenu:!1},{name:"queue",displayName:"APPLICATION_QUEUE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",displayName:"",width:170,cellClass:"text-center ui-grid-vcenter",cellTemplate:'
', +enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1}],data:[],gridMenuTitleFilter:function(a){var b=l.defer();return b.resolve(d.instant(a)),b.promise},onRegisterApi:function(b){a.gridApi=b,a.gridApi.grid.registerDataChangeCallback(function(){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length)}),a.gridApi.treeBase.on.rowExpanded(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length+b.treeNode.children.length)}),a.gridApi.treeBase.on.rowCollapsed(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length-b.treeNode.children.length)}),a.gridApi.core.on.sortChanged(a,function(a,b){0===b.length?s.order=null:s.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),n()}),a.gridApi.pagination.on.paginationChanged(a,function(a,b){s.offset=(a-1)*b,s.limit=b,n()}),a.gridApi.core.on.filterChanged(a,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?s[a.name]=a.filters[0].term:delete s[a.name]}),n()})}},n(),q(),r(),o()};var t=function(a){var b=a?30*a+130:270;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px"),angular.element(document.getElementsByClassName("ui-grid-viewport")).css("height",30*a+"px")};a.$on("$destroy",function(){e.unsyncUpdates("agent"),e.unsyncUpdates("user_has_fax_queue")}),a.pause=function(a,b,c){return i.save({name:b,agent:a,type:c||"DEFAULT PAUSE",data4:c||"DEFAULT PAUSE",channel:"fax"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.joinQueue=function(e){var g=c.open({animation:!0,templateUrl:"app/channels/fax/realtime/view/agent/queue.modal.add.html",controller:"FaxRealtimeViewAgentQueueModalCtrl",resolve:{queues:function(){return _.reject(a.faxQueues,function(b){return _.find(a.gridOptions.data,{queue:b.name,isAgent:!1,agentId:e})?!0:!1})}}});g.result.then(function(b){return i.save({name:"QueueAdd",agent:e,queues:_.filter(a.faxQueues,function(a){return _.includes(b.queues,a.id)}),channel:"fax",data1:e,data3:b.queues.join(","),data4:"fax"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},function(){b.info("Modal dismissed at: "+new Date)})},a.leaveQueue=function(a,b){return i.save({name:"QueueRemove",agent:a,queueId:b,channel:"fax",data1:a,data3:b,data4:"fax"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.showInfo=function(a){c.open({animation:!0,templateUrl:"app/channels/fax/realtime/view/agent/agent.modal.info.html",controller:"FaxRealtimeViewAgentInfoModalCtrl",resolve:{agent:a}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.realtime.view.agents",{url:"/agents",templateUrl:"app/channels/fax/realtime/view/agent/agent.html",controller:"FaxRealtimeViewAgentCtrl"})}]),angular.module("xCallyShuttleApp").controller("FaxRealtimeViewAgentInfoModalCtrl",["$scope","$uibModalInstance","$http","agent",function(a,b,c,d){a.agent=d,a.close=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("FaxRealtimeViewAgentQueueModalCtrl",["$scope","$uibModalInstance","$http","queues",function(a,b,c,d){a.queues=d,a.item={},a.save=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("FaxRealtimeViewCtrl",["$scope","$state",function(a,b){a.agents=[{name:"Queues",link:"main.channels.fax.realtime.view.agents.queues"},{name:"Timeline",link:"main.channels.fax.realtime.view.agents.timeline"}],a.sessions=[{name:"Sessions",link:"main.channels.fax.realtime.view.sessions"}],a.tree={queues:[{name:"Queues",link:"main.channels.fax.realtime.view.agents.queues"},{name:"Timeline",link:"main.channels.fax.realtime.view.agents.timeline"}],sessions:[{name:"Sessions",link:"main.channels.fax.realtime.view.sessions"}]}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.realtime.view",{url:"/view",templateUrl:"app/channels/fax/realtime/view/view.html",controller:"FaxRealtimeViewCtrl"})}]),angular.module("xCallyShuttleApp").factory("MailAccount",["$resource",function(a){return a("/api/mail/accounts/:accountId/:controller/:id",{id:"@accountId"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts",{url:"/accounts",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("MailAccountListCtrl",["$scope","gridOptions","MailAccount","$stateParams",function(a,b,c,d){a.initView=function(){var e={exporterCsvFilename:"mail_accounts.csv",columnDefs:[{name:"name"},{name:"description"},{name:"address"},{name:"MailServerIn.state",width:100,cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.MailServerIn.state}}
",displayName:"IMAP",enableSorting:!1,enableFiltering:!1},{name:"MailServerOut.state",width:110,cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.MailServerOut.state}}
",displayName:"SMTP",enableSorting:!1,enableFiltering:!1},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/mail/accounts/view/{{row.entity.id}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,e,a,{accountId:d.accountId})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.list",{url:"/list",templateUrl:"app/channels/mail/account/list/list.html",controller:"MailAccountListCtrl"})}]),angular.module("xCallyShuttleApp").factory("MailServerIn",["$resource",function(a){return a("/api/mail/servers/in/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("MailServerOut",["$resource",function(a){return a("/api/mail/servers/out/:id/:controller",{id:"@id"},{update:{method:"PUT"},test:{method:"GET"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view.actions",{url:"/actions",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("MailAccountViewActionListCtrl",["$scope","gridOptions","MailAccount","$http","$translate","$stateParams",function(a,b,c,d,e,f){a.initActons=function(){var d={draggable:!0,exporterCsvFilename:"mail_applications.csv",enableSorting:!1,enableFiltering:!1,columnDefs:[{name:"app",cellClass:"text-center"},{name:"name",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.MailQueue ? row.entity.MailQueue.name : row.entity.User.name}}
"},{name:"timeout",cellClass:"text-center"},{name:"interval",cellClass:"text-center"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/mail/accounts/view/{{row.entity.MailAccountId}}/actions/view/{{row.entity.id}}",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.app, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a,{accountId:f.accountId,controller:"applications"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view.actions.list",{url:"/list",templateUrl:"app/channels/mail/account/view/action/list/list.html",controller:"MailAccountViewActionListCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailAccountViewActionViewCtrl",["$scope","$http","$stateParams","$translate","$location","xAlert","WizardHandler","socket","application","interval","Agent","Interval","MailQueue",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initAction=function(){a.$application=i.application,a.$stateParams=c,a.$interval=j.interval,a.forms={},a.apps=[{name:"Queue",value:"queue"},{name:"Agent",value:"agent"}],b.get("/api/mail/applications/"+c.actionId).success(function(b){if(a.application=b,a.application.alwaysTime=!1,a.application.IntervalId)a.application.intType="list";else switch(a.application.interval){case"*,*,*,*":a.application.intType="always";break;default:a.application.intType="custom"}var c=a.application.interval.split(",");"*"===c[0]?a.application.alwaysTime=!0:(a.application.t_from=moment(new Date),a.application.t_to=moment(new Date),a.application.t_from.hour(c[0].split("-")[0].split(":")[0]),a.application.t_from.minute(c[0].split("-")[0].split(":")[1]),a.application.t_to.hour(c[0].split("-")[1].split(":")[0]),a.application.t_to.minute(c[0].split("-")[1].split(":")[1])),"*"===c[1]?(a.application.wd_from="always",a.application.wd_to="always"):(a.application.wd_from=c[1].split("-")[0],a.application.wd_to=c[1].split("-")[1]),"*"===c[2]?(a.application.md_from="always",a.application.md_to="always"):(a.application.md_from=c[2].split("-")[0],a.application.md_to=c[2].split("-")[1]),"*"===c[3]?(a.application.m_from="always",a.application.m_to="always"):(a.application.m_from=c[3].split("-")[0],a.application.m_to=c[3].split("-")[1]),a.$watch("application.t_from",function(b){a.application.t_from_hm=moment(b).format("HH:mm")}),a.$watch("application.t_to",function(b){a.application.t_to_hm=moment(b).format("HH:mm")})}).error(function(a){console.error(a)})},a.getQueues=function(){return m.get().$promise.then(function(b){a.queues=b.rows})["catch"](function(a){console.error(a)})},a.getAgents=function(){return k.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)})},a.getIntervals=function(){return l.get().$promise.then(function(b){a.intervals=b.rows})["catch"](function(a){console.error(a)})},a.updateItem=function(){var e=["*","*","*","*"],g={app:a.application.app,timeout:a.application.timeout,MailAccountId:c.id};switch(a.application.app){case"agent":g.UserId=a.application.UserId;break;case"queue":g.MailQueueId=a.application.MailQueueId}switch(a.application.intType){case"always":g.interval=e.join(","),delete a.application.IntervalId;break;case"custom":a.application.alwaysTime||(e[0]=a.application.alwaysTime?"*":a.application.t_from_hm+"-"+a.application.t_to_hm),a.application.wd_from&&a.application.wd_to&&"always"===a.application.wd_from&&"always"===a.application.wd_to?e[1]="*":e[1]=a.application.wd_from&&a.application.wd_to?a.application.wd_from+"-"+a.application.wd_to:"*",a.application.md_from&&a.application.md_to&&"always"===a.application.md_from&&"always"===a.application.md_to?e[2]="*":e[2]=a.application.md_from&&a.application.md_to?a.application.md_from+"-"+a.application.md_to:"*",a.application.m_from&&a.application.m_to&&"always"===a.application.m_from&&"always"===a.application.m_to?e[3]="*":e[3]=a.application.m_from&&a.application.m_to?a.application.m_from+"-"+a.application.m_to:"*",g.interval=e.join(","),delete a.application.IntervalId;break;case"list":g.IntervalId=a.application.IntervalId}b.put("/api/mail/applications/"+c.actionId,g).success(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){f.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view.actions.view",{url:"/view/:actionId",templateUrl:"app/channels/mail/account/view/action/view/view.html",controller:"MailAccountViewActionViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailAccountViewActionWizardCtrl",["$scope","$http","Agent","MailQueue","Interval","$stateParams","$translate","$location","xAlert","WizardHandler","socket","application","interval",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initWizard=function(){a.apps=[{name:"Queue",value:"queue"},{name:"Agent",value:"agent"}],a.$application=l.application,a.$stateParams=f,a.$interval=m.interval,a.forms={},a.application={alwaysTime:!0},a.$watch("application.t_from",function(b){a.application.t_from_hm=moment(b).format("HH:mm")}),a.$watch("application.t_to",function(b){a.application.t_to_hm=moment(b).format("HH:mm")})},a.getQueues=function(){return d.get().$promise.then(function(b){a.queues=b.rows})["catch"](function(a){console.error(a)})},a.getAgents=function(){return c.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)})},a.getIntervals=function(){return e.get().$promise.then(function(b){a.intervals=b.rows})["catch"](function(a){console.error(a)})},a.createItem=function(){var c=["*","*","*","*"],d={app:a.application.app,timeout:a.application.timeout,MailAccountId:f.accountId};switch(a.application.app){case"agent":d.UserId=a.application.UserId;break;case"queue":d.MailQueueId=a.application.MailQueueId}switch(a.application.intType){case"always":d.interval=c.join(","),delete a.application.IntervalId;break;case"custom":a.application.alwaysTime||(c[0]=a.application.alwaysTime?"*":a.application.t_from_hm+"-"+a.application.t_to_hm),a.application.wd_from&&a.application.wd_to&&"always"===a.application.wd_from&&"always"===a.application.wd_to?c[1]="*":c[1]=a.application.wd_from&&a.application.wd_to?a.application.wd_from+"-"+a.application.wd_to:"*",a.application.md_from&&a.application.md_to&&"always"===a.application.md_from&&"always"===a.application.md_to?c[2]="*":c[2]=a.application.md_from&&a.application.md_to?a.application.md_from+"-"+a.application.md_to:"*",a.application.m_from&&a.application.m_to&&"always"===a.application.m_from&&"always"===a.application.m_to?c[3]="*":c[3]=a.application.m_from&&a.application.m_to?a.application.m_from+"-"+a.application.m_to:"*",d.interval=c.join(","),delete a.application.IntervalId;break;case"list":d.IntervalId=a.application.IntervalId}b.post("/api/mail/applications",d).success(function(){h.path("/channels/mail/accounts/view/"+f.accountId+"/actions/list")}).error(function(a){console.error(a)})},a.formValidation=function(a){return a},a.next=function(){j.wizard().next()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view.actions.wizard",{url:"/wizard",templateUrl:"app/channels/mail/account/view/action/wizard/wizard.html",controller:"MailAccountViewActionWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailAccountViewCtrl",["$scope","$http","$stateParams","$translate","$location","$timeout","socket","xAlert","MailAccount","MailMessage","MailServerIn","MailServerOut","usSpinnerService",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.CONST_TIMEOUT=3e4,a.$on("$destroy",function(){g.socket.removeAllListeners("mail_message:sent"),g.socket.removeAllListeners("mail_message:failed")}),a.initView=function(){return g.socket.on("mail_message:sent",function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success"),m.stop("spinner-grid")}),g.socket.on("mail_message:failed",function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger"),m.stop("spinner-grid")}),i.get({id:c.accountId}).$promise.then(function(b){a.account=b})["catch"](function(a){h.show(a.message,"danger")})},a.updateItemMailAccount=function(){return i.update({id:c.accountId},{name:a.account.name,description:a.account.description,address:a.account.address,fidelity:a.account.fidelity,timeout:a.account.timeout}).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})},a.updateItemMailServerIn=function(){return k.update({id:a.account.MailServerIn.id},a.account.MailServerIn).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})},a.updateItemMailServerOut=function(){return l.update({id:a.account.MailServerOut.id},a.account.MailServerOut).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})},a.test=function(){return m.spin("spinner-grid"),l.test({id:a.account.MailServerOut.id,controller:"test"}).$promise["finally"](function(){f(function(){m.stop("spinner-grid")},a.CONST_TIMEOUT)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view",{url:"/view/:accountId",templateUrl:"app/channels/mail/account/view/view.html",controller:"MailAccountViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]})}]}}).state("main.channels.mail.accounts.view.settings",{url:"/settings",templateUrl:"app/channels/mail/account/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("MailAccountWizardCtrl",["$scope","$http","$location","$translate","WizardHandler","xAlert","MailAccount",function(a,b,c,d,e,f,g){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initWizard=function(){a.forms={},a.item={MailServerIn:{port:993,ssl:!0,"delete":!1,protocol:"IMAP",filter:"UNSEEN",mailbox:"INBOX",keepalive:!0,authTimeout:5,connTimeout:10},MailServerOut:{port:465,ssl:!0}}},a.goNext=function(){e.wizard().next()},a.formValidation=function(a){return a},a.createItem=function(){return g.save(a.item).$promise.then(function(){c.path("/channels/mail/accounts/list")})["catch"](function(a){f.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.wizard",{url:"/wizard",templateUrl:"app/channels/mail/account/wizard/wizard.html",controller:"MailAccountWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.inbox",{url:"/inbox",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("MailInboxListCtrl",["$scope","$rootScope","$uibModal","MailRoom","gridOptions","uiGridConstants","Auth",function(a,b,c,d,e,f,g){a.loadAgents=function(a){c.open({animation:!0,templateUrl:"app/channels/mail/inbox/view/view.agents.modal.html",controller:"MailInboxViewModalAgentCtrl",resolve:{roomId:a}})},a.initView=function(){var c={exporterCsvFilename:"mail_rooms.csv",enableRowHeaderSelection:g.isAdmin(),columnDefs:[{name:"id",displayName:"",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
#{{row.entity.id}}
",width:75,enableSorting:!1,enableFiltering:!1},{name:"subject"},{name:"from",cellClass:"text-center"},{name:"MailAccount.name",displayName:"Account",cellClass:"text-center",enableSorting:!1,enableFiltering:!1},{name:"users",displayName:"APPLICATION_AGENTS",cellClass:"ui-grid-vcenter",cellTemplate:"
{{(row.entity.Users | map:'fullname').join(', ')}}
",enableSorting:!1,enableFiltering:!1},{name:"status",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.status}}
",filter:{type:f.filter.SELECT,selectOptions:[{value:"NEW",label:"NEW"},{value:"OPEN",label:"OPEN"},{value:"CLOSED",label:"CLOSED"}]},width:100},{name:"createdAt",displayName:"",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
',enableSorting:!1,enableFiltering:!1,width:125},{name:"action",width:175,buttons:[{"class":"blue-hoki",href:"/channels/mail/inbox/view/{{row.entity.id}}/room",name:"open"},{"class":"green-meadow",href:"#",name:"agents",onClick:"grid.appScope.loadAgents(row.entity.id)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.id, row.entity.id)",hide:!g.isAdmin()}]}]};a.gridOptions=e.gridOptions(d,c,a),b.$on("mailMessageEvent",function(){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.inbox.list",{url:"/list",templateUrl:"app/channels/mail/inbox/list/list.html",controller:"MailInboxListCtrl"})}]),angular.module("xCallyShuttleApp").directive("mail",function(){return{templateUrl:"app/channels/mail/inbox/mail/mail.html",restrict:"EA",scope:{mailMessage:"=message"}}}),angular.module("xCallyShuttleApp").directive("note",function(){return{templateUrl:"app/channels/mail/inbox/note/note.html",restrict:"EA",scope:{mailMessage:"=message"}}}),angular.module("xCallyShuttleApp").controller("MailInboxViewModalAgentCtrl",["$scope","$uibModalInstance","$translate","$stateParams","Agent","MailRoom","xAlert","roomId",function(a,b,c,d,e,f,g,h){console.log("roomId",h),a.initModal=function(){a.agents=[],a.item={agents:[]},e.get().$promise.then(function(b){b.rows.forEach(function(b){a.agents.push(b)})})["catch"](function(a){console.error(a)}),f.query({id:d.id||h,controller:"agents"}).$promise.then(function(b){b.forEach(function(b){a.agents.push(b),a.item.agents.push(b.id)})})["catch"](function(a){console.error(a)}),a.modal={dismissable:!0,title:"APPLICATION_MESSAGE_SEND_RETRY",text:"MESSAGE_MESSAGE_SEND_RETRY",buttons:[{classes:"btn btn-success",text:"APPLICATION_RETRY",click:function(a){b.close(a)}},{classes:"btn default",text:"APPLICATION_CANCEL",click:function(a){b.dismiss(a)}}]}},a.ok=function(){return f.update({id:d.id||h,controller:"agents",agents:a.item.agents}).$promise.then(function(){g.show(c.instant("MESSAGE_WELL_DONE"),"success"),b.close()})["catch"](function(a){console.error(a)})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("MailInboxViewCtrl",["$scope","$location","$cookieStore","$stateParams","$translate","$uibModal","CannedAnswer","socket","Agent","MailAccount","MailRoom","MailAttachment","MailMessage","FileUploader","Auth","xAlert","usSpinnerService",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q){var r,s=[];a.onSelectAnswer=function(b){a.form.html+=b,a.selectedAnswer=""},a.getAnswers=function(a){return g.get({key:a}).$promise.then(function(a){return _.map(a.rows,"value")})},a.initRoom=function(){a.Auth=o,a.config={autoHideScrollbar:!1,theme:"light",advanced:{updateOnContentResize:!0},setHeight:781,scrollInertia:0},a.forms={},a.selectedAnswer="",a.form={disabled:!1,from:[],to:[],sto:[],cc:[],scc:[],html:""},h.socket.on("mail_message:save",function(b){return a.mailRoom&&b.MailRoomId===d.id?m.get({id:b.id}).$promise.then(function(b){a.mailRoom.MailMessages.unshift(b)})["catch"](function(a){console.error(a)}):void 0}),r=a.uploader=new n({url:"api/mail/attachments",autoUpload:!0,withCredentials:!0,headers:{Authorization:"Bearer "+c.get("token")}}),r.removeFromQueue=function(a){var b=this;return l["delete"]({id:a.basename}).$promise.then(function(){var c=b.getIndexOfItem(a),d=b.queue[c];d.isUploading&&d.cancel(),b.queue.splice(c,1),d._destroy(),b.progress=b._getTotalProgress(),s=_.reject(s,{basename:a.basename})})["catch"](function(){p.show(e.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},r.onErrorItem=function(){p.show(e.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")},r.onSuccessItem=function(a,b){var c={size:b.size,path:b.path,name:b.name,basename:b.basename,type:b.type};a=_.merge(a,c),s.push(c)},i.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)}),j.get().$promise.then(function(b){a.mailAccounts=b.rows})["catch"](function(a){console.error(a)}),d.id&&k.get({id:d.id}).$promise.then(function(b){a.mailRoom=b,a.form.from.push(b.MailAccount.address);var c=_.last(a.mailRoom.MailMessages);a.form.to=a.form.cc=a.form.bcc=_.union(c.from,c.to,c.cc,c.bcc),a.form.sto=_.remove(a.form.to,function(a){return a!==b.MailAccount.address}),"NEW"===a.mailRoom.status&&k.update({id:d.id},{status:"OPEN"})})["catch"](function(a){console.error(a)})},a.cancel=function(){a.form.disabled=!1,a.form.from=[],a.form.to=[],a.form.sto=[],a.form.cc=[],a.form.scc=[],delete a.form.subject,delete a.form.html},a.updateStatus=function(a){return k.update({id:d.id},{status:a}).$promise.then(function(){p.show(e.instant("MESSAGE_STATUS_UPDATE_SUCCESS"),"success"),b.path("/channels/mail/inbox/list")})["catch"](function(a){p.show(a.message,"danger")})},a.loadAgents=function(){f.open({animation:!0,templateUrl:"app/channels/mail/inbox/view/view.agents.modal.html",controller:"MailInboxViewModalAgentCtrl"})},a.loadTemplate=function(){f.open({animation:!0,templateUrl:"app/channels/mail/inbox/view/view.templates.modal.html",controller:"MailInboxViewModalTemplateCtrl"}).result.then(function(b){a.form.subject=b.template.subject,a.form.html=b.template.html})},a.loadNote=function(){f.open({animation:!0,templateUrl:"app/channels/mail/inbox/view/view.notes.modal.html",controller:"MailInboxViewModalNoteCtrl"})},a.sendMail=function(){var c={},f={subject:a.mailRoom?a.mailRoom.subject:a.form.subject,from:a.form.from,to:a.form.sto||[],cc:a.form.scc||[],html:a.form.html||null,text:a.form.text||null,inReplyTo:c.messageId||null,status:"SENDING",MailAttachments:s};return q.spin("spinner-grid"),a.form.disabled=!0,a.mailRoom?(c=_.last(a.mailRoom.MailMessages,{status:"RECEIVED"}),f.inReplyTo=c.messageId||null,k.save({id:d.id,controller:"messages"},f).$promise.then(function(){p.show(e.instant("MESSAGE_WELL_DONE"),"success"),b.path("/channels/mail/inbox/list")})["catch"](function(){p.show(e.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})["finally"](function(){q.stop("spinner-grid"),a.form.disabled=!1})):m.save(f).$promise.then(function(){p.show(e.instant("MESSAGE_MAIL_MESSAGE_SEND_SUCCESS"),"success"),b.path("/channels/mail/inbox/list")})["catch"](function(){p.show(e.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})["finally"](function(){q.stop("spinner-grid"),a.form.disabled=!1})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.inbox.view",{url:"/view",templateUrl:"app/channels/mail/inbox/view/view.html"}).state("main.channels.mail.inbox.view.compose",{url:"/compose",templateUrl:"app/channels/mail/inbox/view/view.room.html",controller:"MailInboxViewCtrl"}).state("main.channels.mail.inbox.view.room",{url:"/:id/room",templateUrl:"app/channels/mail/inbox/view/view.room.html",controller:"MailInboxViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailInboxViewModalNoteCtrl",["$scope","$uibModalInstance","$stateParams","$translate","MailRoom","xAlert",function(a,b,c,d,e,f){a.initModal=function(){a.item={}},a.ok=function(){return e.save({id:c.id,controller:"messages"},{text:a.item.text,status:"NOTE"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(){f.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})["finally"](function(){b.close()})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("MailInboxViewModalTemplateCtrl",["$scope","$uibModalInstance","Template",function(a,b,c){a.initModal=function(){return a.item={},c.get().$promise.then(function(b){a.templates=b.rows})["catch"](function(a){console.error(a)})},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail",{url:"/mail",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("MailAttachment",["$resource",function(a){return a("/api/mail/attachments/:id/:controller",{id:"@id"})}]),angular.module("xCallyShuttleApp").factory("MailMessage",["$resource",function(a){return a("/api/mail/messages/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("MailReport",["$resource",function(a){return a("/api/report/mails/:id/:controller1/:controller2",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("MailRoom",["$resource",function(a){return a("/api/mail/rooms/:id/:controller",{id:"@id",controller:"@controller"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("MailQueueListCtrl",["$scope","MailQueue","gridOptions","$uibModal","xAlert",function(a,b,c,d,e){a.initView=function(){var d={exporterCsvFilename:"voice_queues.csv",columnDefs:[{name:"name"},{name:"description"},{name:"timeout"},{name:"strategy"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/mail/queues/view/{{row.entity.id}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){var b=d.open({animation:!0,templateUrl:"app/channels/mail/queue/list/list.create.modal.html",controller:"MailQueueListCreateCtrl"});b.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("MailQueueListCreateCtrl",["$scope","$uibModalInstance","$translate","xAlert","MailQueue",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return e.save(a.item).$promise.then(function(a){b.close(a)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.queues.list",{url:"/list",templateUrl:"app/channels/mail/queue/list/list.html",controller:"MailQueueListCtrl"})}]),angular.module("xCallyShuttleApp").factory("MailQueue",["$resource",function(a){return a("/api/mail/queues/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.queues",{url:"/queues",template:"
","abstract":!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/scripts/components-dropdowns.js"]})}]},data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("MailQueueViewCtrl",["$scope","$http","$translate","$stateParams","xAlert","Team","MailQueue",function(a,b,c,d,e,f,g){var h=function(){return{select:function(b){return g.save({id:a.queue.id,controller:"agents"},{agents:b,penalty:a.queue.penalty}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.error(a)})},deselect:function(b){return g["delete"]({id:a.queue.id,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.error(a)})}}};a.getQueue=function(){return g.get({id:d.id}).$promise.then(function(b){b.penalty=0,a.queue=b})["catch"](function(a){console.error(a)})},a.updateMailQueue=function(){return g.update({id:d.id},{name:a.queue.name,description:a.queue.description,timeout:a.queue.timeout,strategy:a.queue.strategy}).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})},a.getTeams=function(){return f.get().$promise.then(function(b){return a.teams=b.rows,g.query({id:d.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindMailQueue(a.teams,_.map(b,function(a){return{id:a.id,penalty:a.UserHasMailQueue.penalty}}),h)})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.queues.view",{url:"/view/:id",templateUrl:"app/channels/mail/queue/view/view.html", +controller:"MailQueueViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.mail.queues.view.settings",{url:"/settings",templateUrl:"app/channels/mail/queue/view/view.settings.html"}).state("main.channels.mail.queues.view.agents",{url:"/agents",templateUrl:"app/channels/mail/queue/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.realtime",{url:"/realtime",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewAgentCtrl",["$scope","$log","$uibModal","$translate","socket","xAlert","Agent","Pause","Action","MailQueue","usSpinnerService","$q","uiGridConstants",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){return k.spin("spinner-grid"),g.get(s).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.data=[],b.rows.forEach(function(a){p(a)})})["catch"](function(a){f.show(a.message,"danger")})["finally"](function(){k.stop("spinner-grid")})}function o(){e.socket.on("agent:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.id,isAgent:!0});if(c){var d=a.gridOptions.data.indexOf(c);a.gridOptions.data[d].online=b.online,a.gridOptions.data[d].lastLoginAt=b.lastLoginAt,a.gridOptions.data[d].pause=b.mailPause,a.gridOptions.data[d].pauseType=b.pauseType,a.gridOptions.data[d].lastPauseAt=b.lastPauseAt,a.gridOptions.data[d].ipaddr=b.ipaddr,a.gridOptions.data[d].port=b.port,a.gridOptions.data[d].fullcontact=b.fullcontact,a.gridOptions.data[d].useragent=b.useragent,a.gridOptions.data[d].lastms=b.lastms,a.gridOptions.data[d].internal=b.internal,_.map(a.gridOptions.data,function(a){a.isAgent||a.agentId!==b.id||(a.online=b.online)})}}),e.socket.on("agent:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.id})}),e.socket.on("user_has_mail_queue:save",function(b){console.log("new queue",b);var c=_.find(a.gridOptions.data,{agentId:b.UserId,isAgent:!0}),d=a.gridOptions.data.indexOf(c);a.gridOptions.data.splice(d+1,0,{isAgent:!1,agentId:b.UserId,queue:b.queue,queueId:b.MailQueueId,agent:b.membername,online:c.online})}),e.socket.on("user_has_mail_queue:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.UserId,queueId:b.MailQueueId})})}function p(b){a.gridOptions.data.push({isAgent:!0,agentId:b.id,agent:b.name,online:b.online,lastLoginAt:b.lastLoginAt,lastPauseAt:b.lastPauseAt,pause:b.mailPause,pauseType:b.pauseType,ipaddr:b.ipaddr,port:b.port,fullcontact:b.fullcontact,useragent:b.useragent,lastms:b.lastms,internal:b.internal,$$treeLevel:0}),b.MailQueues.forEach(function(c){a.gridOptions.data.push({isAgent:!1,agentId:b.id,queue:c.name,queueId:c.id,agent:b.name,online:b.online})})}function q(){return h.get().$promise.then(function(b){a.pauses=b.rows,e.syncUpdates("pause",a.pauses)})["catch"](function(a){f.show(a.message,"danger")})}function r(){return j.get().$promise.then(function(b){a.mailQueues=b.rows,e.syncUpdates("mail_queue",a.mailQueues)})["catch"](function(a){f.show(a.message,"danger")})}a.mailQueues=[];var s={offset:0,limit:10};a.moment=moment,a.initAgents=function(){a.gridOptions={enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,showTreeExpandNoChildren:!0,columnDefs:[{name:"name",displayName:"APPLICATION_AGENT",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.agent}} <{{row.entity.internal}}>
'},{name:"online",displayName:"APPLICATION_ONLINE",width:150,headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
({{hhours}}:{{mminutes}}:{{sseconds}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"ONLINE"},{value:"false",label:"OFFLINE"}]}},{name:"mailPause",width:300,displayName:"APPLICATION_PAUSE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{hhours}}:{{mminutes}}:{{sseconds}}({{row.entity.pauseType}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"PAUSED"},{value:"false",label:"NOT PAUSED"}]},enableSorting:!1,enableColumnMenu:!1},{name:"queue",displayName:"APPLICATION_QUEUE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",displayName:"",width:170,cellClass:"text-center ui-grid-vcenter",cellTemplate:'
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1}],data:[],gridMenuTitleFilter:function(a){var b=l.defer();return b.resolve(d.instant(a)),b.promise},onRegisterApi:function(b){a.gridApi=b,a.gridApi.grid.registerDataChangeCallback(function(){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length)}),a.gridApi.treeBase.on.rowExpanded(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length+b.treeNode.children.length)}),a.gridApi.treeBase.on.rowCollapsed(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length-b.treeNode.children.length)}),a.gridApi.core.on.sortChanged(a,function(a,b){0===b.length?s.order=null:s.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),n()}),a.gridApi.pagination.on.paginationChanged(a,function(a,b){s.offset=(a-1)*b,s.limit=b,n()}),a.gridApi.core.on.filterChanged(a,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?s[a.name]=a.filters[0].term:delete s[a.name]}),n()})}},n(),q(),r(),o()};var t=function(a){var b=a?30*a+130:270;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px"),angular.element(document.getElementsByClassName("ui-grid-viewport")).css("height",30*a+"px")};a.$on("$destroy",function(){e.unsyncUpdates("agent"),e.unsyncUpdates("user_has_mail_queue")}),a.pause=function(a,b,c){return i.save({name:b,agent:a,type:c||"DEFAULT PAUSE",data4:c||"DEFAULT PAUSE",channel:"mail"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.joinQueue=function(e){var g=c.open({animation:!0,templateUrl:"app/channels/mail/realtime/view/agent/queue.modal.add.html",controller:"MailRealtimeViewAgentQueueModalCtrl",resolve:{queues:function(){return _.reject(a.mailQueues,function(b){return _.find(a.gridOptions.data,{queue:b.name,isAgent:!1,agentId:e})?!0:!1})}}});g.result.then(function(b){return i.save({name:"QueueAdd",agent:e,queues:_.filter(a.mailQueues,function(a){return _.includes(b.queues,a.id)}),channel:"mail",data1:e,data3:b.queues.join(","),data4:"mail"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},function(){b.info("Modal dismissed at: "+new Date)})},a.leaveQueue=function(a,b){return i.save({name:"QueueRemove",agent:a,queueId:b,channel:"mail",data1:a,data3:b,data4:"mail"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.showInfo=function(a){c.open({animation:!0,templateUrl:"app/channels/mail/realtime/view/agent/agent.modal.info.html",controller:"MailRealtimeViewAgentInfoModalCtrl",resolve:{agent:a}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.realtime.view.agents",{url:"/agents",templateUrl:"app/channels/mail/realtime/view/agent/agent.html",controller:"MailRealtimeViewAgentCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewAgentInfoModalCtrl",["$scope","$uibModalInstance","$http","agent",function(a,b,c,d){a.agent=d,a.close=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewAgentQueueModalCtrl",["$scope","$uibModalInstance","$http","queues",function(a,b,c,d){a.queues=d,a.item={},a.save=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewQueueCtrl",["$scope","$http","socket","MailQueue","Agent",function(a,b,c,d,e){a.initQueues=function(){a.gridOptions={enableSorting:!1,enableFiltering:!0,enableHorizontalScrollbar:0,enableVerticalScrollbar:0,showTreeExpandNoChildren:!1,columnDefs:[{name:"queueName",displayName:"Queue"},{name:"fullname",displayName:"Agent",cellClass:"text-center"},{name:"online",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'},{name:"chatPause",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
"},{name:"pauseType",cellClass:"text-center",cellTemplate:'{{row.entity.pauseType}}'},{name:"lastLoginAt",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'}],onRegisterApi:function(b){a.gridApi=b,a.gridApi.treeBase.on.rowExpanded(a,function(b){var c=_.findIndex(a.gridOptions.data,{$$hashKey:b.entity.$$hashKey});b.entity.Users&&b.entity.Users.forEach(function(b){_.find(a.gridOptions.data,{name:b.name})||a.gridOptions.data.splice(c+1,0,b)})})}},d.get(function(b){a.gridOptions.data=[],b.rows.forEach(function(b){b.$$treeLevel=0,b.queueName=b.name,a.gridOptions.data.push(b),b.Users&&b.Users.forEach(function(b){b.agentName=b.name,a.gridOptions.data.push(b)})}),c.socket.on("agent:save",function(b){var c=_.filter(a.gridOptions.data,{agentName:b.name});c.forEach(function(a){a.online=b.online,a.lastLoginAt=b.lastLoginAt})}),c.socket.on("mail_queue:save",function(b){b.$$treeLevel=0,b.queueName=b.name,a.gridOptions.data.push(b)}),c.socket.on("mail_queue:remove",function(b){_.remov(a.gridOptions.data,{queueName:b.name})}),c.socket.on("user_has_mail_queue:save",function(b){var c=_.findIndex(a.gridOptions.data,function(a){return a.queueName&&a.id===b.MailQueueId});e.get({id:b.UserId}).$promise.then(function(b){a.gridOptions.data.splice(c+1,0,{id:b.id,name:b.name,fullname:b.fullname,agentName:b.name,online:b.online,lastLoginAt:b.lastLoginAt})})["catch"](function(a){console.error(a)})}),c.socket.on("user_has_mail_queue:remove",function(b){for(var c=_.findIndex(a.gridOptions.data,function(a){return a.queueName&&a.id===b.MailQueueId}),d=c+1;dApril 1, 2014',sort:{direction:d.DESC,priority:1}},{name:"leaveAt",displayName:"leaveAt",cellClass:"text-center",cellTemplate:''},{name:"unmanagedAt",displayName:"unmanangedAt",cellClass:"text-center",cellTemplate:''}],data:[]},b.get("/api/report/mail/sessions").success(function(b){a.gridOptions.data=b.rows,c.socket.on("report_mail_session:save",function(b){var c=_.find(a.gridOptions.data,{id:b.id}),d=a.gridOptions.data.indexOf(c);c?_.merge(a.gridOptions.data[d],b):a.gridOptions.data.unshift(b)})}).error(function(a){console.error(a)})},a.$on("$destroy",function(){c.unsyncUpdates("report_mail:save"),c.unsyncUpdates("report_mail:update")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.realtime.view.sessions",{url:"/sessions",templateUrl:"app/channels/mail/realtime/view/session/session.html",controller:"MailRealtimeViewSessionCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewCtrl",["$scope","$state",function(a,b){a.agents=[{name:"Queues",link:"main.channels.mail.realtime.view.agents.queues"},{name:"Timeline",link:"main.channels.mail.realtime.view.agents.timeline"}],a.sessions=[{name:"Sessions",link:"main.channels.mail.realtime.view.sessions"}],a.tree={queues:[{name:"Queues",link:"main.channels.mail.realtime.view.agents.queues"},{name:"Timeline",link:"main.channels.mail.realtime.view.agents.timeline"}],sessions:[{name:"Sessions",link:"main.channels.mail.realtime.view.sessions"}]}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.realtime.view",{url:"/view",templateUrl:"app/channels/mail/realtime/view/view.html",controller:"MailRealtimeViewCtrl"})}]),angular.module("xCallyShuttleApp").factory("ReportCall",["$resource",function(a){return a("/api/report/calls/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChanSpy",["$resource",function(a){return a("/api/chanspy/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.chanspy",{url:"/chanspy",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChanSpyListCtrl",["$scope","$uibModal","ChanSpy","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"chanspy.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/channels/voice/chanspy/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/channels/voice/chanspy/list/list.create.modal.html",controller:"ChanSpyListCreateCtrl"});c.result.then(function(b){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("ChanSpyListCreateCtrl",["$scope","$translate","$uibModalInstance","ChanSpy","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.options=[{name:"APPLICATION_CHANSPY_OPTION_b",value:"b"},{name:"APPLICATION_CHANSPY_OPTION_B",value:"B"},{name:"APPLICATION_CHANSPY_OPTION_E",value:"E"},{name:"APPLICATION_CHANSPY_OPTION_o",value:"o"},{name:"APPLICATION_CHANSPY_OPTION_q",value:"q"},{name:"APPLICATION_CHANSPY_OPTION_s",value:"s"},{name:"APPLICATION_CHANSPY_OPTION_S",value:"S"},{name:"APPLICATION_CHANSPY_OPTION_w",value:"w"},{name:"APPLICATION_CHANSPY_OPTION_W",value:"W"}],a.save=function(){return a.item.options=a.item.options.join(""),d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.chanspy.list",{url:"/list",templateUrl:"app/channels/voice/chanspy/list/list.html",controller:"ChanSpyListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChanSpyViewCtrl",["$scope","$translate","$stateParams","xAlert","ChanSpy",function(a,b,c,d,e){a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.options=[{name:"APPLICATION_CHANSPY_OPTION_b",value:"b"},{name:"APPLICATION_CHANSPY_OPTION_B",value:"B"},{name:"APPLICATION_CHANSPY_OPTION_E",value:"E"},{name:"APPLICATION_CHANSPY_OPTION_o",value:"o"},{name:"APPLICATION_CHANSPY_OPTION_q",value:"q"},{name:"APPLICATION_CHANSPY_OPTION_s",value:"s"},{name:"APPLICATION_CHANSPY_OPTION_S",value:"S"},{name:"APPLICATION_CHANSPY_OPTION_w",value:"w"},{name:"APPLICATION_CHANSPY_OPTION_W",value:"W"}],a.getChanSpy=function(){return e.get({id:c.id}).$promise.then(function(b){b.options=b.options.split(""),a.chanspy=b})["catch"](function(a){d.show(a.data.message,"danger")})},a.updateChanSpy=function(){var f=angular.copy(a.chanspy);return f.options=f.options.join(""),e.update({id:c.id},f).$promise.then(function(){d.show(b.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){d.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.chanspy.view",{url:"/view/:id",templateUrl:"app/channels/voice/chanspy/view/view.html",controller:"ChanSpyViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.chanspy.view.settings",{url:"/settings",templateUrl:"app/channels/voice/chanspy/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("VoiceContext",["$resource",function(a){return a("/api/voice/contexts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.contexts",{url:"/contexts",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceContextListCtrl",["$scope","VoiceContext","gridOptions","$uibModal","xAlert","$translate",function(a,b,c,d,e,f){a.initView=function(){var d={exporterCsvFilename:"voice_contexts.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:170,buttons:[{"class":"{{row.entity.defaultEntry ? 'blue-hoki disabled' : 'blue-hoki'}}",href:"/channels/voice/contexts/view/{{row.entity.id}}/settings",name:"settings"},{"class":"{{row.entity.defaultEntry ? 'red-sunglo disabled' : 'red-sunglo'}}",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){var c=d.open({animation:!0,templateUrl:"app/channels/voice/context/list/create.modal.html",controller:["$scope","$uibModalInstance",function(a,b){a.form={},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]});c.result.then(function(c){return b.save(c).$promise.then(function(){a.gridOptions.getPage(),e.show(f.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){e.show(a.data.message,"danger")})})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.contexts.list",{url:"/list",templateUrl:"app/channels/voice/context/list/list.html",controller:"VoiceContextListCtrl"})}]),angular.module("xCallyShuttleApp").controller("VoiceContextViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location",function(a,b,c,d,e,f){a.getContext=function(){b.get("/api/voice/contexts/"+e.id).success(function(b){a.context=b}).error(function(a){console.error(a),f.path("/voice/contexts/list")})},a.updateVoiceContext=function(){var f=angular.copy(a.context);b.put("/api/voice/contexts/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(b){c.show(d.instant(b.message),"danger"),a.context=f})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.contexts.view",{url:"/view/:id",templateUrl:"app/channels/voice/context/view/view.html",controller:"VoiceContextViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.contexts.view.settings",{url:"/settings",templateUrl:"app/channels/voice/context/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("VoiceMohListCtrl",["$scope","gridOptions","VoiceMoh","$uibModal","xAlert","$translate",function(a,b,c,d,e,f){a.initView=function(){var d={exporterCsvFilename:"voice_mohs.csv",columnDefs:[{name:"name"},{name:"directory"},{name:"sort"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/voice/mohs/view/{{row.entity.id}}/settings",name:"settings"},{"class":"{{row.entity.defaultEntry ? 'red-sunglo disabled' : 'red-sunglo'}}",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a)},a.createItem=function(){var b=d.open({animation:!0,templateUrl:"app/channels/voice/moh/list/create.modal.html",controller:["$scope","$uibModalInstance",function(a,b){a.form={},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]});b.result.then(function(b){return c.save(b).$promise.then(function(){a.gridOptions.getPage(),e.show(f.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.mohs.list",{url:"/list",templateUrl:"app/channels/voice/moh/list/list.html",controller:"VoiceMohListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("VoiceMoh",["$resource",function(a){return a("/api/voice/musiconholds/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.mohs",{url:"/mohs",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceMohViewCtrl",["$scope","$http","xAlert","$translate","VoiceMoh","$stateParams","socket","Modal","$sce","$location","Sound",function(a,b,c,d,e,f,g,h,i,j,k){a.$translate=d,a.audioSources={},a.sortOptions=[{value:"random",name:"APPLICATION_RANDOM"},{value:"alpha",name:"APPLICATION_ALPHABETICAL"}],a.getMoh=function(){return e.get({id:f.id}).$promise.then(function(b){delete b.stamp,a.moh=b})["catch"](function(a){c.show(a.message,"danger")})},a.updateVoiceMoh=function(){return console.log("update"),e.update({id:f.id},a.moh).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){c.show(a.message,"danger")})},a.addMohs=function(){return e.save({id:f.id,controller:"files"},a.item).$promise.then(function(){j.path("/channels/voice/mohs/view/"+f.id+"/audios")})["catch"](function(a){c.show(a.message,"danger")})},a.getAudioFiles=function(){return e.get({id:f.id,controller:"files"}).$promise.then(function(b){a.audioFiles=b.files,a.mohPath=b.path,a.audioFiles.forEach(function(a){l(a)})})["catch"](function(a){c.show(a.message,"danger")})},a.getSecureSrc=function(a){return i.trustAsResourceUrl(a)},a.getSounds=function(){return a.item={sounds:[]},k.get().$promise.then(function(b){a.soundList=b.rows})["catch"](function(a){c.show(a.message,"danger")})};var l=function(c){b.get("/api/voice/musiconholds/stream",{params:{path:encodeURI(a.mohPath+"/"+c)}}).success(function(b){a.audioSources[c]="data:audio/ogg;base64,"+b}).error(function(a){console.error(a)})};a.deleteItem=h.confirm["delete"](function(e){b["delete"]("/api/voice/musiconholds/"+f.id+"/files",{params:{filename:e}}).success(function(){_.remove(a.audioFiles,function(a){return a===e}),c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(a){c.show(a.message,"danger")})})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.mohs.view",{url:"/view/:id",templateUrl:"app/channels/voice/moh/view/view.html",controller:"VoiceMohViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.mohs.view.settings",{url:"/settings",templateUrl:"app/channels/voice/moh/view/view.settings.html"}).state("main.channels.voice.mohs.view.audios",{url:"/audios",templateUrl:"app/channels/voice/moh/view/view.audios.html",cache:!1}).state("main.channels.voice.mohs.view.add",{url:"/add",templateUrl:"app/channels/voice/moh/view/view.addFiles.html",cache:!1})}]),angular.module("xCallyShuttleApp").controller("VoiceQueueListCtrl",["$scope","$rootScope","VoiceQueue","gridOptions","$uibModal",function(a,b,c,d,e){a.initView=function(){var b={exporterCsvFilename:"voice_queues.csv",primaryKey:"name",columnDefs:[{name:"name"},{name:"strategy"},{name:"description"},{name:"action",width:200,buttons:[{"class":"blue-hoki",href:"/channels/voice/queues/view/{{row.entity.name}}/settings",name:"settings"},{"class":"green-meadow",href:"/channels/voice/queues/view/{{row.entity.name}}/agents",name:"agents"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.name)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var b=e.open({animation:!0,templateUrl:"app/channels/voice/queue/list/list.create.modal.html",controller:"VoiceQueueListCreateCtrl"});b.result.then(function(){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("VoiceQueueListCreateCtrl",["$scope","$uibModalInstance","$translate","xAlert","VoiceQueue",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return e.save(a.item).$promise.then(function(a){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),b.close(a)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.queues.list",{url:"/list",templateUrl:"app/channels/voice/queue/list/list.html",controller:"VoiceQueueListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.queues",{url:"/queues",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("ReportQueue",["$resource",function(a){return a("/api/report/queues/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("VoiceQueueViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","socket","$location","VoiceQueue","VoiceContext","Team",function(a,b,c,d,e,f,g,h,i,j){a.penalty=0,a.binaryChoices=[{name:"Yes",value:1},{name:"No",value:0}],a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.monitorFormats=[{name:"wav",value:"wav"},{name:"gsm",value:"gsm"},{name:"Inactive",value:""}],a.queueAnnounces=[{display_name:"Default",value:null},{display_name:"Disabled",value:""}];var k=function(){return{select:function(b){return h.save({id:a.queue.name,controller:"agents"},{agents:b,penalty:a.queue.penalty}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})},deselect:function(b){return h["delete"]({id:a.queue.name,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})}}};a.getQueue=function(){return h.get({id:e.id}).$promise.then(function(b){b.joinempty=""===b.joinempty?[]:b.joinempty.split(","),b.leavewhenempty=""===b.leavewhenempty?[]:b.leavewhenempty.split(","),b.periodic_announce=""===b.periodic_announce?[]:b.periodic_announce.split(","),b.penalty=0,a.queue=b})["catch"](function(a){g.path("/channels/voice/queues/list")})},a.updateVoiceQueue=function(){var b=angular.copy(a.queue);return b.joinempty=b.joinempty.join(","),b.leavewhenempty=b.leavewhenempty.join(","), +b.periodic_announce=b.periodic_announce.join(","),b.context||(b.context=null),h.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(d.instant(a.data.message),"danger")})},a.getTeams=function(){return j.get().$promise.then(function(b){return a.teams=b.rows,h.query({id:e.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindQueue(a.teams,_.map(b,function(a){return{id:a.id,penalty:a.UserHasVoiceQueue.penalty}}),k)})["catch"](function(a){console.error(a)})},a.getContexts=function(){return i.get().$promise.then(function(b){a.voiceContexts=b.rows})["catch"](function(a){c.show(d.instant(data.message),"danger")})},a.getMohs=function(){b.get("/api/voice/musiconholds").success(function(b){a.voiceMohs=b.rows,f.syncUpdates("voice_musiconhold",a.voiceMohs)}).error(function(a){c.show(a.message,"danger")})},a.getSounds=function(){b.get("/api/sounds").success(function(b){a.queueAnnounces=a.queueAnnounces.concat(b),a.periodicAnnounces=angular.copy(b.rows),b.rows.unshift({display_name:"None",converted_path:null,value:""}),a.sounds=b.rows,f.syncUpdates("sound",a.sounds)}).error(function(a){console.error(a)})},a.returnAnnouncePath=function(a){return a.converted_path?a.converted_path+"/"+a.save_name:null===a.value?null:a.value}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.queues.view",{url:"/view/:id",templateUrl:"app/channels/voice/queue/view/view.html",controller:"VoiceQueueViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.queues.view.settings",{url:"/settings",templateUrl:"app/channels/voice/queue/view/view.settings.html"}).state("main.channels.voice.queues.view.agents",{url:"/agents",templateUrl:"app/channels/voice/queue/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}})}]),angular.module("xCallyShuttleApp").factory("VoiceQueue",["$resource",function(a){return a("/api/voice/queues/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.realtime",{url:"/realtime",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewAgentCtrl",["$scope","$log","$uibModal","$translate","socket","xAlert","Agent","Pause","Action","VoiceQueue","usSpinnerService","$q","uiGridConstants",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){return k.spin("spinner-grid"),g.get(s).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.data=[],b.rows.forEach(function(a){p(a)})})["catch"](function(a){f.show(a.message,"danger")})["finally"](function(){k.stop("spinner-grid")})}function o(){e.socket.on("agent:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.id,isAgent:!0});if(c){var d=a.gridOptions.data.indexOf(c);a.gridOptions.data[d].online=b.online,a.gridOptions.data[d].lastLoginAt=b.lastLoginAt,a.gridOptions.data[d].pause=b.voicePause,a.gridOptions.data[d].pauseType=b.pauseType,a.gridOptions.data[d].lastPauseAt=b.lastPauseAt,a.gridOptions.data[d].status=b.status,a.gridOptions.data[d].statusAt=b.statusAt,a.gridOptions.data[d].queueStatus=b.queueStatus,a.gridOptions.data[d].queueStatusAt=b.queueStatusAt,a.gridOptions.data[d].lastQueue=b.lastQueue,a.gridOptions.data[d].ipaddr=b.ipaddr,a.gridOptions.data[d].port=b.port,a.gridOptions.data[d].fullcontact=b.fullcontact,a.gridOptions.data[d].useragent=b.useragent,a.gridOptions.data[d].lastms=b.lastms,a.gridOptions.data[d].internal=b.internal,_.map(a.gridOptions.data,function(a){a.isAgent||a.agentId!==b.id||(a.online=b.online)})}}),e.socket.on("agent:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.id})}),e.socket.on("user_has_voice_queue:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.UserId,queue:b.queue});if(!c&&b.logged){var d=_.find(a.gridOptions.data,{agentId:b.UserId,isAgent:!0}),e=a.gridOptions.data.indexOf(d);a.gridOptions.data.splice(e+1,0,{isAgent:!1,agentId:b.UserId,queue:b.queue,agent:b.membername,callstaken:b.callstaken?b.callstaken:0,online:d.online})}else c&&!b.logged?_.remove(a.gridOptions.data,{agentId:b.UserId,queue:b.queue}):c&&b.logged&&(c.callstaken=b.callstaken?b.callstaken:0)}),e.socket.on("user_has_voice_queue:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.UserId,queue:b.queue})})}function p(b){a.gridOptions.data.push({isAgent:!0,agentId:b.id,agent:b.name,online:b.online,lastLoginAt:b.lastLoginAt,lastPauseAt:b.lastPauseAt,pause:b.voicePause,pauseType:b.pauseType,status:b.status||"UNKNOWN",statusAt:b.statusAt,queueStatus:b.queueStatus||"READY",queueStatusAt:b.queueStatusAt,lastQueue:b.lastQueue,ipaddr:b.ipaddr,port:b.port,fullcontact:b.fullcontact,useragent:b.useragent,lastms:b.lastms,internal:b.internal,$$treeLevel:0}),b.VoiceQueues.forEach(function(c){c.UserHasVoiceQueue.logged&&a.gridOptions.data.push({isAgent:!1,agentId:b.id,queue:c.name,agent:b.name,callstaken:c.UserHasVoiceQueue.callstaken?c.UserHasVoiceQueue.callstaken:0,online:b.online})})}function q(){return h.get().$promise.then(function(b){a.pauses=b.rows,e.syncUpdates("pause",a.pauses)})["catch"](function(a){f.show(a.message,"danger")})}function r(){return j.get().$promise.then(function(b){a.voiceQueues=b.rows,e.syncUpdates("voice_queue",a.voiceQueues)})["catch"](function(a){f.show(a.message,"danger")})}a.voiceQueues=[];var s={offset:0,limit:10};a.moment=moment,a.initAgents=function(){a.gridOptions={enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,showTreeExpandNoChildren:!0,columnDefs:[{name:"name",displayName:"APPLICATION_AGENT",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.agent}} <{{row.entity.internal}}>
'},{name:"online",displayName:"APPLICATION_ONLINE",width:150,headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
({{hhours}}:{{mminutes}}:{{sseconds}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"ONLINE"},{value:"false",label:"OFFLINE"}]}},{name:"status",displayName:"APPLICATION_PHONE_STATUS",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{'APPLICATION_'+row.entity.status | translate}} ({{hhours}}:{{mminutes}}:{{sseconds}})
",filter:{type:m.filter.SELECT,selectOptions:[{value:"UNKNOWN",label:d.instant("APPLICATION_UNKNOWN")},{value:"NOT_INUSE",label:d.instant("APPLICATION_NOT_INUSE")},{value:"INUSE",label:d.instant("APPLICATION_INUSE")},{value:"BUSY",label:d.instant("APPLICATION_BUSY")},{value:"INVALID",label:d.instant("APPLICATION_INVALID")},{value:"UNAVAILABLE",label:d.instant("APPLICATION_UNAVAILABLE")},{value:"RINGING",label:d.instant("APPLICATION_RINGING")},{value:"RINGINUSE",label:d.instant("APPLICATION_RINGINUSE")},{value:"ONHOLD",label:d.instant("APPLICATION_ONHOLD")}]}},{name:"queueStatus",width:400,displayName:"APPLICATION_QUEUE_STATUS",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{\'APPLICATION_\'+row.entity.queueStatus.toUpperCase() | translate}} [{{row.entity.lastQueue}}] [{{row.entity.pauseType}}] [{{hhours}}:{{mminutes}}:{{sseconds}}]
',filter:{type:m.filter.SELECT,selectOptions:[{value:"paused",label:d.instant("APPLICATION_PAUSED")},{value:"connect",label:d.instant("APPLICATION_CONNECT")},{value:"complete",label:d.instant("APPLICATION_COMPLETE")},{value:"called",label:d.instant("APPLICATION_CALLED")}]},enableSorting:!1,enableColumnMenu:!1},{name:"queue",displayName:"APPLICATION_QUEUE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"callstaken",displayName:"APPLICATION_CALLS_TAKEN",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.callstaken}}
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1,width:100},{name:"action",displayName:"",width:170,cellClass:"text-center ui-grid-vcenter",cellTemplate:'
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1}],data:[],gridMenuTitleFilter:function(a){var b=l.defer();return b.resolve(d.instant(a)),b.promise},onRegisterApi:function(b){a.gridApi=b,a.gridApi.grid.registerDataChangeCallback(function(){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length)}),a.gridApi.treeBase.on.rowExpanded(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length+b.treeNode.children.length)}),a.gridApi.treeBase.on.rowCollapsed(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length-b.treeNode.children.length)}),a.gridApi.core.on.sortChanged(a,function(a,b){0===b.length?s.order=null:s.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),n()}),a.gridApi.pagination.on.paginationChanged(a,function(a,b){s.offset=(a-1)*b,s.limit=b,n()}),a.gridApi.core.on.filterChanged(a,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?s[a.name]=a.filters[0].term:delete s[a.name]}),n()})}},n(),q(),r(),o()};var t=function(a){var b=a?30*a+130:270;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px"),angular.element(document.getElementsByClassName("ui-grid-viewport")).css("height",30*a+"px")};a.$on("$destroy",function(){e.unsyncUpdates("agent"),e.unsyncUpdates("user_has_voice_queue")}),a.pause=function(a,b,c){return i.save({name:b,agent:a,type:c||"DEFAULT PAUSE",data4:c||"DEFAULT PAUSE",channel:"voice"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(d.instant(a.message||a.data.message||a.translatedMessage||a.data.translatedMessage),"danger")})},a.joinQueue=function(e){var g=c.open({animation:!0,templateUrl:"app/channels/voice/realtime/view/agent/queue.modal.add.html",controller:"VoiceRealtimeViewAgentQueueModalCtrl",resolve:{queues:function(){return _.reject(a.voiceQueues,function(b){return _.find(a.gridOptions.data,{queue:b.name,isAgent:!1,agentId:e})?!0:!1})}}});g.result.then(function(a){return i.save({name:"QueueAdd",agent:e,queues:a.queues,channel:"voice",data1:e,data3:a.queues.join(","),data4:"voice"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},function(){b.info("Modal dismissed at: "+new Date)})},a.leaveQueue=function(a,b){return i.save({name:"QueueRemove",agent:a,queue:b,channel:"voice",data1:a,data3:b,data4:"voice"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.showInfo=function(a){c.open({animation:!0,templateUrl:"app/channels/voice/realtime/view/agent/agent.modal.info.html",controller:"VoiceRealtimeViewAgentInfoModalCtrl",resolve:{agent:a}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.realtime.view.agents",{url:"/agents",templateUrl:"app/channels/voice/realtime/view/agent/agent.html",controller:"VoiceRealtimeViewAgentCtrl"})}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewAgentInfoModalCtrl",["$scope","$uibModalInstance","$http","agent",function(a,b,c,d){a.agent=d,a.close=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewAgentQueueModalCtrl",["$scope","$uibModalInstance","$http","queues",function(a,b,c,d){a.queues=d,a.item={},a.save=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewAgentReportCtrl",["$scope","$http","socket",function(a,b,c){a.$on("$destroy",function(){c.unsyncUpdates("report_agent")}),a.conf={agentsByPage:{name:"10",value:10},labels:["fullname","name","email"]},a.agentsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.initReport=function(){a.agents=[],b.get("/api/report/agents").success(function(b){a.agents=b,c.syncUpdates("report_agent",a.agents)}).error(function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").filter("VoiceRealtimeViewAgentReportFilter",function(){return function(a){return new Date(1970,0,1).setSeconds(a)}}),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewQueueReportCtrl",["$scope","$http","socket",function(a,b,c){a.$on("$destroy",function(){c.unsyncUpdates("report_queue")}),a.conf={queuesByPage:{name:"10",value:10},labels:["fullname","name","email"]},a.queuesByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.initReport=function(){a.queues=[],b.get("/api/report/queues").success(function(b){console.log(b),a.queues=b,c.syncUpdates("report_queue",a.queues)}).error(function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").filter("VoiceRealtimeViewQueueReportFilter",function(){return function(a){return new Date(1970,0,1).setSeconds(a)}}),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewQueuePauseModalCtrl",["$scope","$uibModalInstance","items","data",function(a,b,c,d){a.items=c,a.data=d,console.log(d),a.selected={item:a.items[0],queue:_.isArray(d)?a.data[0].queue:a.data.queue,membername:_.isArray(d)?a.data[0].membername:a.data.membername,"interface":_.isArray(d)?a.data[0]["interface"]:a.data["interface"]},a.ok=function(c,e){var f;_.isArray(d)?(f=[],d.forEach(function(b){f.push({action:"QueuePause",queue:b.queue,membername:b.membername,"interface":b["interface"],paused:c,reason:a.selected.item})})):f={action:"QueuePause",queue:a.selected.queue,membername:a.selected.membername,"interface":a.selected["interface"],paused:c,reason:a.selected.item},b.close(f)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewQueueCtrl",["$scope","$http","$log","$uibModal","$translate","socket","xAlert",function(a,b,c,d,e,f,g){a.conf={agentsByPage:{name:"10",value:10},labels:["fullname","name","email"]},a.agentsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.$on("$destroy",function(){f.unsyncUpdates("user_has_voice_queue")}),a.groups=[],a.pauses=["pausa1","pausa2","pausa3"],a.pause=function(f,h){var i=d.open({animation:!0,size:f,templateUrl:"app/channels/voice/realtime/view/queue/pause.modal.html",controller:"VoiceRealtimeViewQueuePauseModalCtrl",resolve:{items:function(){return a.pauses},data:function(){return h}}});i.result.then(function(a){_.isArray(a)?a.forEach(function(a){b.post("/api/ami",a).then(function(a){console.log(a),g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.log(a),g.show(a.data.message,"danger")})}):b.post("/api/ami",a).then(function(a){console.log(a),g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.log(a),g.show(a.data.message,"danger")})},function(){c.info("Modal dismissed at: "+new Date)})},a.add=function(f,h){var i=d.open({animation:!0,size:f,templateUrl:"app/channels/voice/realtime/view/queue/queue.modal.add.html",controller:"VoiceRealtimeViewQueueQueueModalCtrl",resolve:{pauses:function(){return a.pauses},data:function(){return h}}});i.result.then(function(a){console.log("action",a),b.post("/api/voice/user_has_queues",a).then(function(){a.login?b.post("/api/ami",a).then(function(){g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")}):g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.message,"danger")}),console.log(a)},function(){c.info("Modal dismissed at: "+new Date)})},a.remove=function(a,f){var h=d.open({animation:!0,size:a,templateUrl:"app/channels/voice/realtime/view/queue/queue.modal.remove.html",controller:"VoiceRealtimeViewQueueQueueModalCtrl",resolve:{pauses:function(){return null},data:function(){return f}}});h.result.then(function(a){_.isArray(a)?a.forEach(function(a){b.post("/api/ami",a).then(function(){a.logout?b.put("/api/voice/queues/"+a.queue+"/agents",{agents:[a.UserId]}).then(function(){g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")}):g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")})}):b.post("/api/ami",a).then(function(){a.logout?b.put("/api/voice/queues/"+a.queue+"/agents",{agents:[a.UserId]}).then(function(){g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")}):g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")})},function(){c.info("Modal dismissed at: "+new Date)})},a.initQueues=function(){b.get("/api/voice/user_has_queues").success(function(b){a.queues=b,a.groups=_.map(_.groupBy(a.queues,"queue"),function(a,b){return{queue:b,agents:a}}),console.log("ok"),f.socket.on("user_has_voice_queue:save",function(b){console.log("item",b);var c=_.find(a.groups,{queue:b.queue}),d=a.groups.indexOf(c);if(c){var e=_.find(c.agents,{membername:b.membername});e?_.merge(e,b):a.groups[d].agents.push(b)}else{var f={queue:b.queue,agents:[b]};a.groups.unshift(f)}}),f.socket.on("user_has_voice_queue:remove",function(b){var c=_.find(a.groups,{queue:b.queue});_.remove(c.agents,{membername:b.membername}),c.agents.length||_.remove(a.groups,{queue:b.queue})}),f.socket.on("report_agent:save",function(b){var c=_.find(a.groups,{queue:b.queue}),d=a.groups.indexOf(c);if(c){var e=_.find(c.agents,{membername:b.membername});e?_.merge(e,b):a.groups[d].agents.push(b)}else{var f={queue:b.queue,agents:[b]};a.groups.unshift(f)}})}).error(function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewQueueQueueModalCtrl",["$scope","$uibModalInstance","$http","pauses","data",function(a,b,c,d,e){a.initAdd=function(){a.data=e,a.pauses=d,a.selected={penalty:0,paused:!1,reason:a.pauses[0]},a.$watch("selected.agent",function(b){b&&(a.selected.membername=b.name,a.selected["interface"]="SIP/"+b.name,a.selected.UserId=b.id)}),c.get("/api/agents",{params:{page:0,per_page:500}}).success(function(b){a.agents=_.reject(b.rows,function(b){return _.find(a.data,{membername:b.name})?!0:!1}),a.selected.queue=a.data[0]?a.data[0].queue:null}).error(function(a){console.error(a)})},a.initRemove=function(){a.data=e,console.log(e),_.isArray(e)?a.selected={queue:a.data[0].queue,logout:!1}:a.selected={membername:a.data.membername,"interface":a.data["interface"],queue:a.data.queue,logout:!1,UserId:a.data.UserId}},a.okAdd=function(){var c={action:"QueueAdd",queue:a.selected.queue,membername:a.selected.membername,"interface":a.selected["interface"],penalty:a.selected.penalty,paused:a.selected.paused,UserId:a.selected.UserId};c.paused&&(c.reason=a.selected.reason),b.close(c)},a.okRemove=function(){var c;_.isArray(a.data)?(c=[],a.data.forEach(function(b){c.push({action:"QueueRemove",queue:b.queue,"interface":b["interface"],logout:a.selected.logout,UserId:b.UserId})})):c={action:"QueueRemove",queue:a.selected.queue,logout:a.selected.logout,"interface":a.selected["interface"],UserId:a.selected.UserId},b.close(c)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewCtrl",["$scope",function(a){a.agents=[{name:"View1",link:"main.channels.voice.realtime.view.agents"},{name:"View2",link:"main.channels.voice.realtime.view.areports"}],a.queues=[{name:"View1",link:"main.channels.voice.realtime.view.queues"},{name:"View2",link:"main.channels.voice.realtime.view.qreports"}]}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.realtime.view",{url:"/view",templateUrl:"app/channels/voice/realtime/view/view.html",controller:"VoiceRealtimeViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("VoiceRecordingListCtrl",["$scope","$translate","$sce","Recording","gridOptions","xAlert","uiGridConstants",function(a,b,c,d,e,f,g){a.Recording=d;a.updateRating=function(a,c){d.patch({id:a,rating:c}).$promise.then(function(){f.show(b.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.initView=function(){var b={exporterCsvFilename:"recordings.csv",rowHeight:30,columnDefs:[{name:"uniqueid"},{name:"calleridnum"},{name:"calleridname"},{name:"connectedlinenum"},{name:"connectedlinename"},{name:"rating",filter:{type:g.filter.SELECT,selectOptions:[{value:1,label:"1"},{value:2,label:"2"},{value:3,label:"3"},{value:4,label:"4"},{value:5,label:"5"}]},cellClass:"ui-grid-vcenter",width:"100",cellTemplate:'
'},{name:"audio",displayName:"",width:225,enableSorting:!1,enableFiltering:!1,buttons:[{directive:''}]},{name:"action",width:150,buttons:[{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.uniqueid, row.entity.uniqueid)"},{directive:''}]}]};a.gridOptions=e.gridOptions(d,b,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.recordings.list",{url:"/list",templateUrl:"app/channels/voice/recording/list/list.html",controller:"VoiceRecordingListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Recording",["$resource",function(a){return a("/api/voice/recordings/:id/:controller",{id:"@id"},{update:{method:"PUT"},patch:{method:"PATCH"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.recordings",{url:"/recordings",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.inbound",{url:"/inbound",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInboundListCreateCtrl",["$scope","$uibModalInstance","Route","application","xAlert","$location","$translate",function(a,b,c,d,e,f,g){a.$application=d.application,a.forms={route:void 0},a.item={type:"inbound",appdata:"Inbound Call",context:"from-voip-provider"},a.ok=function(){return a.item.exten=a.$application.checkUnderscore(a.item.exten),c.save(a.item).$promise.then(function(a){b.close(a),f.path("/channels/voice/routes/inbound/view/"+a.id+"/applications")})["catch"](function(a){console.log(a),e.show(g.instant(a.data.translatedMessage),"danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInboundListCtrl",["$scope","$http","socket","$translate","$rootScope","xAlert","Modal","stResource","gridOptions","Route","$uibModal","$location","$log",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.initView=function(){var b={exporterCsvFilename:"InboundRoutes.csv",columnDefs:[{name:"exten",displayName:"APPLICATION_PHONE_NUMBER"},{name:"description"},{name:"applications",cellClass:"ui-grid-vcenter",cellTemplate:'
{{app.app}}({{app.appdata[0]}}), ...
{{\'MESSAGE_NO_AVAILABLE_APPLICATIONS\' | translate}}
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",width:170,buttons:[{"class":"blue-hoki",href:"/channels/voice/routes/inbound/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.exten, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(j,b,a,{type:"inbound"})},a.create=function(){k.open({animation:!0,templateUrl:"app/channels/voice/route/inbound/list/create.modal.html",controller:"VoiceRouteInboundListCreateCtrl"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.inbound.list",{url:"/list",templateUrl:"app/channels/voice/route/inbound/list/list.html",controller:"VoiceRouteInboundListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInboundViewCtrl",["$scope","$translate","$stateParams","socket","$location","WizardHandler","Modal","xAlert","application","interval","Route","VoiceQueue","Sound","SquareProject","VoiceContext","Interval","VoiceMail",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q){function r(b){var c,d;if("always"===b.intType)c=null,d="*,*,*,*";else if("list"===b.intType)d=b.IntervalId?_.find(a.Intervals,{id:b.IntervalId}).name:"*,*,*,*",c=b.IntervalId||null;else if("custom"===b.intType){c=null;var e,f,g,h;e=b.t_from&&b.t_to&&!b.alwaysTime?moment(b.t_from).format("HH:mm")+"-"+moment(b.t_to).format("HH:mm"):"*",b.wd_from&&"always"!==b.wd_from?(f=b.wd_from,b.wd_to&&"always"!==b.wd_to&&(f+="-"+b.wd_to)):f="*",b.md_from&&"always"!==b.md_from?(g=b.md_from,b.md_to&&"always"!==b.md_to&&(g+="-"+b.md_to)):g="*",b.m_from&&"always"!==b.m_from?(h=b.m_from,b.m_to&&"always"!==b.m_to&&(h+="-"+b.m_to)):h="*",d=e+","+f+","+g+","+h}void 0===a.selectedApp?(a.application.interval=d,a.application.IntervalId=c):(a.route.Applications[a.selectedApp].interval=d,a.route.Applications[a.selectedApp].IntervalId=c)}function s(){if(a.interval.intType=a.route.Applications[a.selectedApp].IntervalId?"list":"*,*,*,*"===a.route.Applications[a.selectedApp].interval?"always":"custom",a.interval.IntervalId=a.route.Applications[a.selectedApp].IntervalId,!a.route.Applications[a.selectedApp].IntervalId){var b,c=a.route.Applications[a.selectedApp].interval?a.route.Applications[a.selectedApp].interval.split(","):["*","*","*","*"];c.forEach(function(c,d){switch(d){case 0:"*"!==c?(b=c.split("-"),a.interval.t_from=moment(b[0],"HH:mm"),a.interval.t_to=moment(b[1],"HH:mm"),a.interval.alwaysTime=!1):(a.interval.t_from=moment(new Date),a.interval.t_to=moment(new Date),a.interval.alwaysTime=!0);break;case 1:"*"!==c?(b=c.split("-"),a.interval.wd_from=b[0],a.interval.wd_to=b[1]?b[1]:"always"):(a.interval.wd_from="always",a.interval.wd_to="always");break;case 2:"*"!==c?(b=c.split("-"),a.interval.md_from=b[0],a.interval.md_to=b[1]?b[1]:"always"):(a.interval.md_from="always",a.interval.md_to="always");break;case 3:"*"!==c?(b=c.split("-"),a.interval.m_from=b[0],a.interval.m_to=b[1]?b[1]:"always"):(a.interval.m_from="always",a.interval.m_to="always")}})}}a.$translate=b,a.$application=i.application,a.$interval=j.interval,a.gridOptions={rowTemplate:'
',columnDefs:[{name:"app",displayName:"APPLICATION_APPLICATION",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"appdata",displayName:"APPLICATION_ARGUMENTS",headerCellFilter:"translate",cellClass:"ui-grid-vcenter",cellTemplate:"
{{row.entity.appdata.join(',')}}
",enableSorting:!1,enableColumnMenu:!1},{name:"interval",displayName:"APPLICATION_TIME",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"action",enableSorting:!1,enableColumnMenu:!1,displayName:"APPLICATION_ACTION",headerCellFilter:"translate",width:125,cellTemplate:'{{\'APPLICATION_SETTINGS\' | translate}}{{\'APPLICATION_DELETE\' | translate}}'}],onRegisterApi:function(b){b.draggableRows.on.rowDropped(a,function(b,c){a.updateRoute()})}},a.initApplication=function(b){b&&(a.selectedApp=void 0),a.forms={settings:void 0,interval:void 0},a.application={},a.interval={intType:"always",t_from:moment(new Date),t_to:moment(new Date),wd_from:"always",wd_to:"always",md_from:"always",md_to:"always", +m_from:"always",m_to:"always",alwaysTime:!0},a.main={app:""}},a.$watch("interval",function(a){a&&r(a)},!0),a.updateSetAppdata=function(){a.application.variable&&a.application.value&&"Set"===a.main.app?a.application.appdata[0]=a.application.variable+"="+a.application.value:a.application.appdata[0]=null},a.updateSetAppdataSettings=function(){a.application.variable&&a.application.value&&"Set"===a.main.app?a.route.Applications[a.selectedApp].appdata[0]=a.application.variable+"="+a.application.value:a.application.appdata[0]=null},a.$watch("main.app",function(d){if(d){var e,f;switch(c.appId||(a.application={app:d,interval:a.application.interval||"*,*,*,*",appdata:[]}),d){case"Queue":e=l,f=m;break;case"Playback":e=m;break;case"AGI":e=n;break;case"Goto":e=o;break;case"Voicemail":e=q;break;default:e=null,f=null}if(e)return e.get().$promise.then(function(b){a.items=b.rows}).then(function(){return f?f.get().$promise:void 0}).then(function(b){b&&(a.items2=b.rows)})["catch"](function(a){h.show(b.instant(a.message),"danger")})}},!0),a.deselectAndRedirect=function(b){a.selectedApp=void 0,e.path(b)},a.getIntervals=function(){return p.get().$promise.then(function(b){a.Intervals=b.rows,d.syncUpdates("interval",a.Intervals)})["catch"](function(a){h.show(b.instant(a.message),"danger")})},a.getRoute=function(){return k.get({id:c.id}).$promise.then(function(b){a.route=b,a.gridOptions.data=b.Applications})["catch"](function(a){e.path("/channels/voice/routes/inbound/list")})},a.getApplication=function(){void 0===a.selectedApp&&e.path("/channels/voice/routes/inbound/list");var b=_.find(a.$application.applications,{value:a.route.Applications[a.selectedApp].app});if(a.main.app=b?b.value:"custom","Set"===a.main.app){var c=a.route.Applications[a.selectedApp].appdata[0].split("=");a.application.variable=c[0],a.application.value=c[1]}if(!b){var d=a.route.Applications[a.selectedApp].appdata.join(",");a.route.Applications[a.selectedApp].appdata=[d]}s()},a.openApplication=function(b){a.selectedApp=b,e.path("/channels/voice/routes/inbound/view/"+c.id+"/applications/settings")},a.updateRoute=function(d){return a.selectedApp=void 0,a.route.exten=a.$application.checkUnderscore(a.route.exten),k.update({id:a.route.id},a.route).$promise.then(function(a){h.show(b.instant("MESSAGE_WELL_DONE")+"!","success"),d&&e.path("/channels/voice/routes/inbound/view/"+c.id+"/"+d)})["catch"](function(a){console.log(a),h.show(b.instant(a.data.translatedMessage),"danger")})},a.getContexts=function(){return o.get().$promise.then(function(b){a.voiceContexts=b.rows,d.syncUpdates("voice_context",a.voiceContexts)})["catch"](function(a){h.show(b.instant(a.message),"danger")})},a.deleteApp=g.confirm["delete"](function(b){console.log(b),console.log(a.route.Applications[b]),a.route.Applications.splice(b,1)}),a.addApplication=function(){a.route.Applications.push(a.application),a.updateRoute("applications")},a.goNext=function(){f.wizard().next()},a.previous=function(){f.wizard().previous()},a.formValidation=function(a){return a},a.$on("destroy",function(){d.unsyncUpdates("voice_extension")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.inbound.view",{url:"/view/:id",templateUrl:"app/channels/voice/route/inbound/view/view.html",controller:"VoiceRouteInboundViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.routes.inbound.view.settings",{url:"/settings",templateUrl:"app/channels/voice/route/inbound/view/view.settings.html"}).state("main.channels.voice.routes.inbound.view.applications",{url:"/applications",templateUrl:"app/channels/voice/route/inbound/view/view.applications.html"}).state("main.channels.voice.routes.inbound.view.application",{url:"/application",templateUrl:"app/channels/voice/route/view.application.html"}).state("main.channels.voice.routes.inbound.view.applications.settings",{url:"/settings",templateUrl:"app/channels/voice/route/view.applicationSettings.html"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.internal",{url:"/internal",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInternalListCreateCtrl",["$scope","$uibModalInstance","Route","application","$location","$translate","xAlert",function(a,b,c,d,e,f,g){a.$application=d.application,a.forms={route:void 0},a.item={type:"internal",appdata:"Internal Call",context:"from-sip"},a.ok=function(){return a.item.exten=a.$application.checkUnderscore(a.item.exten),c.save(a.item).$promise.then(function(a){b.close(a),e.path("/channels/voice/routes/internal/view/"+a.id+"/applications")})["catch"](function(a){g.show(f.instant(a.data.translatedMessage),"danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInternalListCtrl",["$scope","$http","socket","$translate","$rootScope","xAlert","Modal","stResource","gridOptions","Route","$uibModal","$location","$log",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.initView=function(){var b={exporterCsvFilename:"InternalRoutes.csv",columnDefs:[{name:"exten",displayName:"APPLICATION_PHONE_NUMBER"},{name:"description"},{name:"applications",cellClass:"ui-grid-vcenter",cellTemplate:'
{{app.app}}({{app.appdata[0]}}),...
{{\'MESSAGE_NO_AVAILABLE_APPLICATIONS\' | translate}}
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",width:170,buttons:[{"class":"blue-hoki",href:"/channels/voice/routes/internal/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.exten, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(j,b,a,{type:"internal"})},a.create=function(){k.open({animation:!0,templateUrl:"app/channels/voice/route/internal/list/create.modal.html",controller:"VoiceRouteInternalListCreateCtrl"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.internal.list",{url:"/list",templateUrl:"app/channels/voice/route/internal/list/list.html",controller:"VoiceRouteInternalListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInternalViewCtrl",["$scope","$translate","$stateParams","socket","$location","WizardHandler","Modal","xAlert","application","interval","Route","VoiceQueue","Sound","SquareProject","VoiceContext","Interval","VoiceMail",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q){function r(b){var c,d;if("always"===b.intType)c=null,d="*,*,*,*";else if("list"===b.intType)d=b.IntervalId?_.find(a.Intervals,{id:b.IntervalId}).name:"*,*,*,*",c=b.IntervalId||null;else if("custom"===b.intType){c=null;var e,f,g,h;e=b.t_from&&b.t_to&&!b.alwaysTime?moment(b.t_from).format("HH:mm")+"-"+moment(b.t_to).format("HH:mm"):"*",b.wd_from&&"always"!==b.wd_from?(f=b.wd_from,b.wd_to&&"always"!==b.wd_to&&(f+="-"+b.wd_to)):f="*",b.md_from&&"always"!==b.md_from?(g=b.md_from,b.md_to&&"always"!==b.md_to&&(g+="-"+b.md_to)):g="*",b.m_from&&"always"!==b.m_from?(h=b.m_from,b.m_to&&"always"!==b.m_to&&(h+="-"+b.m_to)):h="*",d=e+","+f+","+g+","+h}void 0===a.selectedApp?(a.application.interval=d,a.application.IntervalId=c):(a.route.Applications[a.selectedApp].interval=d,a.route.Applications[a.selectedApp].IntervalId=c)}function s(){if(a.interval.intType=a.route.Applications[a.selectedApp].IntervalId?"list":"*,*,*,*"===a.route.Applications[a.selectedApp].interval?"always":"custom",a.interval.IntervalId=a.route.Applications[a.selectedApp].IntervalId,!a.route.Applications[a.selectedApp].IntervalId){var b,c=a.route.Applications[a.selectedApp].interval?a.route.Applications[a.selectedApp].interval.split(","):["*","*","*","*"];c.forEach(function(c,d){switch(d){case 0:"*"!==c?(b=c.split("-"),a.interval.t_from=moment(b[0],"HH:mm"),a.interval.t_to=moment(b[1],"HH:mm"),a.interval.alwaysTime=!1):(a.interval.t_from=moment(new Date),a.interval.t_to=moment(new Date),a.interval.alwaysTime=!0);break;case 1:"*"!==c?(b=c.split("-"),a.interval.wd_from=b[0],a.interval.wd_to=b[1]?b[1]:"always"):(a.interval.wd_from="always",a.interval.wd_to="always");break;case 2:"*"!==c?(b=c.split("-"),a.interval.md_from=b[0],a.interval.md_to=b[1]?b[1]:"always"):(a.interval.md_from="always",a.interval.md_to="always");break;case 3:"*"!==c?(b=c.split("-"),a.interval.m_from=b[0],a.interval.m_to=b[1]?b[1]:"always"):(a.interval.m_from="always",a.interval.m_to="always")}})}}a.$translate=b,a.selectedApp=void 0,a.$application=i.application,a.$interval=j.interval,a.gridOptions={rowTemplate:'
',columnDefs:[{name:"app",displayName:"APPLICATION_APPLICATION",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"appdata",displayName:"APPLICATION_ARGUMENTS",headerCellFilter:"translate",cellClass:"ui-grid-vcenter",cellTemplate:"
{{row.entity.appdata.join(',')}}
",enableSorting:!1,enableColumnMenu:!1},{name:"interval",displayName:"APPLICATION_TIME",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"action",displayName:"APPLICATION_ACTION",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1,width:125,cellTemplate:'{{\'APPLICATION_SETTINGS\' | translate}}{{\'APPLICATION_DELETE\' | translate}}'}],onRegisterApi:function(b){b.draggableRows.on.rowDropped(a,function(b,c){a.updateRoute()})}},a.initApplication=function(b){b&&(a.selectedApp=void 0),a.forms={settings:void 0,interval:void 0},a.application={},a.interval={intType:"always",t_from:moment(new Date),t_to:moment(new Date),wd_from:"always",wd_to:"always",md_from:"always",md_to:"always",m_from:"always",m_to:"always",alwaysTime:!0},a.main={app:""}},a.$watch("interval",function(a){a&&r(a)},!0),a.updateSetAppdata=function(){a.application.variable&&a.application.value&&"Set"===a.main.app?a.application.appdata[0]=a.application.variable+"="+a.application.value:a.application.appdata[0]=null},a.updateSetAppdataSettings=function(){a.application.variable&&a.application.value&&"Set"===a.main.app?a.route.Applications[a.selectedApp].appdata[0]=a.application.variable+"="+a.application.value:a.application.appdata[0]=null},a.$watch("main.app",function(d){if(d){var e,f;switch(c.appId||(a.application={app:d,interval:a.application.interval||"*,*,*,*",appdata:[]}),d){case"Queue":e=l,f=m;break;case"Playback":e=m;break;case"AGI":e=n;break;case"Goto":e=o;break;case"Voicemail":e=q;break;default:e=null,f=null}if(e)return e.get().$promise.then(function(b){a.items=b.rows}).then(function(){return f?f.get().$promise:void 0}).then(function(b){b&&(a.items2=b.rows)})["catch"](function(a){h.show(b.instant(a.message),"danger")})}},!0),a.deselectAndRedirect=function(b){a.selectedApp=void 0,e.path(b)},a.getIntervals=function(){return p.get().$promise.then(function(b){a.Intervals=b.rows,d.syncUpdates("interval",a.Intervals)})["catch"](function(a){h.show(b.instant(a.message),"danger")})},a.getRoute=function(){return k.get({id:c.id}).$promise.then(function(b){a.route=b,a.gridOptions.data=b.Applications})["catch"](function(a){e.path("/channels/voice/routes/internal/list")})},a.getApplication=function(){console.log(a.selectedApp),void 0===a.selectedApp&&e.path("/channels/voice/routes/internal/list");var b=_.find(a.$application.applications,{value:a.route.Applications[a.selectedApp].app});if(a.main.app=b?b.value:"custom","Set"===a.main.app){var c=a.route.Applications[a.selectedApp].appdata[0].split("=");a.application.variable=c[0],a.application.value=c[1]}if(!b){var d=a.route.Applications[a.selectedApp].appdata.join(",");a.route.Applications[a.selectedApp].appdata=[d]}s()},a.openApplication=function(b){a.selectedApp=b,e.path("/channels/voice/routes/internal/view/"+c.id+"/applications/settings")},a.updateRoute=function(d){return a.selectedApp=void 0,a.route.exten=a.$application.checkUnderscore(a.route.exten),k.update({id:a.route.id},a.route).$promise.then(function(a){h.show(b.instant("MESSAGE_WELL_DONE")+"!","success"),d&&e.path("/channels/voice/routes/internal/view/"+c.id+"/"+d)})["catch"](function(a){h.show(b.instant(a.data.translatedMessage),"danger")})},a.getContexts=function(){return o.get().$promise.then(function(b){a.voiceContexts=b.rows,d.syncUpdates("voice_context",a.voiceContexts)})["catch"](function(a){h.show(b.instant(a.message),"danger")})},a.deleteApp=g.confirm["delete"](function(b){a.route.Applications.splice(b,1),a.updateRoute()}),a.addApplication=function(){a.route.Applications.push(a.application),a.updateRoute("applications")},a.goNext=function(){f.wizard().next()},a.previous=function(){f.wizard().previous()},a.formValidation=function(a){return a},a.$on("destroy",function(){d.unsyncUpdates("voice_extension")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.internal.view",{url:"/view/:id",templateUrl:"app/channels/voice/route/internal/view/view.html",controller:"VoiceRouteInternalViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.routes.internal.view.settings",{url:"/settings",templateUrl:"app/channels/voice/route/internal/view/view.settings.html"}).state("main.channels.voice.routes.internal.view.applications",{url:"/applications",templateUrl:"app/channels/voice/route/internal/view/view.applications.html"}).state("main.channels.voice.routes.internal.view.application",{url:"/application",templateUrl:"app/channels/voice/route/view.application.html"}).state("main.channels.voice.routes.internal.view.applications.settings",{url:"/settings",templateUrl:"app/channels/voice/route/view.applicationSettings.html"})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteOutboundListCreateCtrl",["$scope","$uibModalInstance","Route","application","xAlert","$translate","$location","Tag",function(a,b,c,d,e,f,g,h){a.$application=d.application,a.forms={route:void 0},a.item={type:"outbound",appdata:"Outbound Call",context:"from-sip"},a.getTags=function(){return h.get().$promise.then(function(b){b.rows.unshift({name:"--"}),a.tags=b.rows})["catch"](function(a){e.show(f.instant(a.data.translatedMessage),"danger")})},a.ok=function(){return a.item.exten=a.$application.checkUnderscore(a.item.exten),c.save(a.item).$promise.then(function(a){b.close(a),g.path("/channels/voice/routes/outbound/view/"+a.id+"/routes")})["catch"](function(a){e.show(f.instant(a.data.translatedMessage),"danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRouteOutboundListCtrl",["$scope","$http","socket","$translate","$rootScope","xAlert","Modal","stResource","gridOptions","Route","$uibModal","$location","$log",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.initView=function(){var b={exporterCsvFilename:"OutboundRoutes.csv",columnDefs:[{name:"exten",displayName:"APPLICATION_DESTINATION_PATTERN"},{name:"description"},{name:"applications",cellClass:"ui-grid-vcenter",cellTemplate:'
{{app.app}}({{app.appdata[0]}}),...
{{\'MESSAGE_NO_AVAILABLE_APPLICATIONS\' | translate}}
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",width:170,buttons:[{"class":"blue-hoki",href:"/channels/voice/routes/outbound/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.exten, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(j,b,a,{type:"outbound"})},a.create=function(){k.open({animation:!0,templateUrl:"app/channels/voice/route/outbound/list/create.modal.html",controller:"VoiceRouteOutboundListCreateCtrl"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.outbound.list",{url:"/list",templateUrl:"app/channels/voice/route/outbound/list/list.html",controller:"VoiceRouteOutboundListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.outbound",{url:"/outbound",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteOutboundViewCtrl",["$scope","xAlert","$translate","$stateParams","socket","$location","WizardHandler","Modal","application","interval","Route","Trunk","VoiceContext","Interval","Tag",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o){function p(b){var c,d;if("always"===b.intType)c=null,d="*,*,*,*";else if("list"===b.intType)d=b.IntervalId?_.find(a.Intervals,{id:b.IntervalId}).name:"*,*,*,*",c=b.IntervalId||null;else if("custom"===b.intType){c=null;var e,f,g,h;e=b.t_from&&b.t_to&&!b.alwaysTime?moment(b.t_from).format("HH:mm")+"-"+moment(b.t_to).format("HH:mm"):"*",b.wd_from&&"always"!==b.wd_from?(f=b.wd_from,b.wd_to&&"always"!==b.wd_to&&(f+="-"+b.wd_to)):f="*",b.md_from&&"always"!==b.md_from?(g=b.md_from,b.md_to&&"always"!==b.md_to&&(g+="-"+b.md_to)):g="*",b.m_from&&"always"!==b.m_from?(h=b.m_from,b.m_to&&"always"!==b.m_to&&(h+="-"+b.m_to)):h="*",d=e+","+f+","+g+","+h}void 0===a.selectedApp?(a.application.interval=d,a.application.IntervalId=c):(a.route.Applications[a.selectedApp].interval=d,a.route.Applications[a.selectedApp].IntervalId=c)}function q(){if(a.interval.intType=a.route.Applications[a.selectedApp].IntervalId?"list":"*,*,*,*"===a.route.Applications[a.selectedApp].interval?"always":"custom",a.interval.IntervalId=a.route.Applications[a.selectedApp].IntervalId,!a.route.Applications[a.selectedApp].IntervalId){var b,c=a.route.Applications[a.selectedApp].interval?a.route.Applications[a.selectedApp].interval.split(","):["*","*","*","*"];c.forEach(function(c,d){switch(d){case 0:"*"!==c?(b=c.split("-"),a.interval.t_from=moment(b[0],"HH:mm"),a.interval.t_to=moment(b[1],"HH:mm"),a.interval.alwaysTime=!1):(a.interval.t_from=moment(new Date),a.interval.t_to=moment(new Date),a.interval.alwaysTime=!0);break;case 1:"*"!==c?(b=c.split("-"),a.interval.wd_from=b[0],a.interval.wd_to=b[1]?b[1]:"always"):(a.interval.wd_from="always",a.interval.wd_to="always");break;case 2:"*"!==c?(b=c.split("-"),a.interval.md_from=b[0],a.interval.md_to=b[1]?b[1]:"always"):(a.interval.md_from="always",a.interval.md_to="always");break;case 3:"*"!==c?(b=c.split("-"),a.interval.m_from=b[0],a.interval.m_to=b[1]?b[1]:"always"):(a.interval.m_from="always",a.interval.m_to="always")}})}}a.$translate=c,a.$application=i.application,a.$interval=j.interval,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.gridOptions={rowTemplate:'
',columnDefs:[{name:"app",displayName:"APPLICATION_APPLICATION",cellClass:"ui-grid-vcenter",cellTemplate:"
Default{{row.entity.app}}
",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"appdata",displayName:"APPLICATION_ARGUMENTS",headerCellFilter:"translate",cellClass:"ui-grid-vcenter",cellTemplate:"
{{row.entity.appdata.join(',')}}
",enableSorting:!1,enableColumnMenu:!1},{name:"interval",displayName:"APPLICATION_TIME",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"action",displayName:"APPLICATION_ACTION",enableSorting:!1,enableColumnMenu:!1,headerCellFilter:"translate",width:125,cellTemplate:'{{\'APPLICATION_SETTINGS\' | translate}}{{\'APPLICATION_DELETE\' | translate}}'}],onRegisterApi:function(b){b.draggableRows.on.rowDropped(a,function(b,c){a.updateRoute()})}},a.initApplication=function(b){b&&(a.selectedApp=void 0),a.forms={info:void 0,interval:void 0},a.application={},a.interval={intType:"always",t_from:moment(new Date),t_to:moment(new Date),wd_from:"always",wd_to:"always",md_from:"always",md_to:"always",m_from:"always",m_to:"always",alwaysTime:!0},a.main={app:""},a.applications=[{name:"Default",value:"Dial"},{name:"Custom",value:"custom"}]},a.$watch("interval",function(a){a&&p(a)},!0),a.$watch("main.app",function(e){if(e){var f,g;switch(d.appId||(a.application={app:e,interval:a.application.interval||"*,*,*,*",appdata:[]}),e){case"Dial":f=l,g=m;break;default:f=null,g=null}if(f)return f.get().$promise.then(function(b){a.items=b.rows}).then(function(){return g?g.get().$promise:void 0}).then(function(b){b&&(a.items2=b.rows)})["catch"](function(a){b.show(c.instant(a.message),"danger")})}},!0),a.deselectAndRedirect=function(b){a.selectedApp=void 0,f.path(b)},a.getIntervals=function(){return n.get().$promise.then(function(b){a.Intervals=b.rows,e.syncUpdates("interval",a.Intervals)})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.getRoute=function(){return k.get({id:d.id}).$promise.then(function(b){a.route=b,a.gridOptions.data=b.Applications})["catch"](function(a){f.path("/channels/voice/routes/outbound/list")})},a.getApplication=function(){void 0===a.selectedApp&&f.path("/channels/voice/routes/outbound/list");var b=_.find(a.applications,{value:a.route.Applications[a.selectedApp].app});if(a.main.app=b?b.value:"custom",!b){var c=a.route.Applications[a.selectedApp].appdata.join(",");a.route.Applications[a.selectedApp].appdata=[c]}q()},a.openApplication=function(b){a.selectedApp=b,f.path("/channels/voice/routes/outbound/view/"+d.id+"/routes/settings")},a.updateRoute=function(e){return a.selectedApp=void 0,a.route.exten=a.$application.checkUnderscore(a.route.exten),k.update({id:a.route.id},a.route).$promise.then(function(a){b.show(c.instant("MESSAGE_WELL_DONE")+"!","success"),e&&f.path("/channels/voice/routes/outbound/view/"+d.id+"/"+e)})["catch"](function(a){b.show(c.instant(a.data.translatedMessage),"danger")})},a.getContexts=function(){return m.get().$promise.then(function(b){a.voiceContexts=b.rows,e.syncUpdates("voice_context",a.voiceContexts)})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.getTags=function(){return o.get().$promise.then(function(b){b.rows.unshift({name:"--"}),a.tags=b.rows})["catch"](function(a){b.show(c.instant(a.data.translatedMessage),"danger")})},a.deleteApp=h.confirm["delete"](function(b){a.route.Applications.splice(b,1),a.updateRoute()}),a.addApplication=function(){a.route.Applications.push(a.application),a.updateRoute("routes")},a.goNext=function(){g.wizard().next()},a.previous=function(){g.wizard().previous()},a.formValidation=function(a){return a},a.$on("destroy",function(){e.unsyncUpdates("voice_extension")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.outbound.view",{url:"/view/:id",templateUrl:"app/channels/voice/route/outbound/view/view.html",controller:"VoiceRouteOutboundViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.routes.outbound.view.settings",{url:"/settings",templateUrl:"app/channels/voice/route/outbound/view/view.settings.html"}).state("main.channels.voice.routes.outbound.view.routes",{url:"/routes",templateUrl:"app/channels/voice/route/outbound/view/view.routes.html"}).state("main.channels.voice.routes.outbound.view.route",{url:"/route",templateUrl:"app/channels/voice/route/outbound/view/view.route.html"}).state("main.channels.voice.routes.outbound.view.routes.settings",{url:"/settings",templateUrl:"app/channels/voice/route/outbound/view/view.routeSettings.html"})}]),angular.module("xCallyShuttleApp").factory("Route",["$resource",function(a){return a("/api/voice/extensions/:id",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes",{url:"/routes",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice",{url:"/voice",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("VoiceVoicemailListCtrl",["$scope","VoiceMail","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"voice_mails.csv",primaryKey:"uniqueid",columnDefs:[{name:"mailbox"},{name:"fullname"},{name:"email"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/voice/voicemails/view/{{row.entity.uniqueid}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.mailbox, row.entity.uniqueid)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.voicemails.list",{url:"/list",templateUrl:"app/channels/voice/voicemail/list/list.html",controller:"VoiceVoicemailListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("VoiceVoicemailViewCtrl",["$scope","VoiceMail","VoiceMailMessage","VoiceContext","$http","xAlert","$translate","$stateParams","socket","$sce","Modal","$location","gridOptions",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){var b={exporterCsvFilename:"voice_mail_messages.csv",primaryKey:"id",columnDefs:[{name:"callerid"},{name:"stamp",displayName:"APPLICATION_DATE",cellClass:"ui-grid-vcenter",cellTemplate:"
{{grid.appScope.moment(row.entity.stamp).format('YYYY-MM-DD HH:mm:ss')}}
"},{name:"duration",cellClass:"ui-grid-vcenter",cellTemplate:"
{{row.entity.duration*1000 | date:'mm:ss'}}
"},{name:"audio",displayName:"",width:225,enableSorting:!1,enableFiltering:!1,buttons:[{directive:''}]},{name:"action",width:150,buttons:[{directive:''},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.id, row.entity.id)"}]}]};a.gridOptions=m.gridOptions(c,b,a,{mailbox:a.voicemail.mailbox,context:a.voicemail.context})}a.moment=moment,a.VoiceMailMessage=c,a.getVoicemail=function(){return b.get({id:h.uniqueid}).$promise.then(function(b){delete b.password,delete b.stamp,a.voicemail=b})["catch"](function(a){l.path("/voice/voicemails/list")})},a.updateVoiceVoicemail=function(){return b.update({id:h.uniqueid},a.voicemail).$promise.then(function(){f.show(g.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(g.instant(a.message),"danger")})},a.getContexts=function(){return d.get().$promise.then(function(b){a.voiceContexts=b.rows})["catch"](function(a){f.show(a.message,"danger")})},a.getMessages=function(){return a.voicemail?void n():b.get({id:h.uniqueid}).$promise.then(function(b){delete b.password,delete b.stamp,a.voicemail=b,n()})["catch"](function(a){l.path("/voice/voicemails/view/"+h.uniqueid+"/settings")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.voicemails.view",{url:"/view/:uniqueid",templateUrl:"app/channels/voice/voicemail/view/view.html",controller:"VoiceVoicemailViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.voicemails.view.settings",{url:"/settings",templateUrl:"app/channels/voice/voicemail/view/view.settings.html"}).state("main.channels.voice.voicemails.view.messages",{url:"/messages",templateUrl:"app/channels/voice/voicemail/view/view.messages.html"})}]),angular.module("xCallyShuttleApp").factory("VoiceMail",["$resource",function(a){return a("/api/voice/voicemails/:id/:controller",{uniqueid:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.voicemails",{url:"/voicemails",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("VoiceMailMessage",["$resource",function(a){return a("/api/voice/voicemails/messages/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("VoiceVoicemailWizardCtrl",["$scope","VoiceMail","xAlert","WizardHandler","$location","Setting",function(a,b,c,d,e,f){a.initWizard=function(){a.form={},a.item={context:"from-voicemail"}},a.next=function(){d.wizard().next()},a.previous=function(){d.wizard().previous()},a.exitValidation=function(a){return a},a.getFirstFreeMailbox=function(){f.get({controller:"mailbox"}).$promise.then(function(b){a.item.mailbox=b.value})["catch"](function(a){c.show(a.data.message,"danger")})},a.createItem=function(){return a.item.customer_id=a.item.mailbox,b.save(a.item).$promise.then(function(){e.path("/channels/voice/voicemails/list")})["catch"](function(a){c.show(data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.voicemails.wizard",{url:"/wizard",templateUrl:"app/channels/voice/voicemail/wizard/wizard.html",controller:"VoiceVoicemailWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("VoiceQueue",["$resource",function(a){return a("/api/voice/queues/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("Company",["$resource",function(a){return a("/api/contactmanager/companies/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.companies",{url:"/companies",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("CompanyListCreateModalCtrl",["$scope","$uibModalInstance",function(a,b){ +a.forms={dashboard:void 0},a.item={},a.ok=function(){a.item.model=JSON.stringify({title:a.item.name}),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ContactManagerCompanyListCtrl",["$scope","$http","$translate","xAlert","Modal","$uibModal","$log","Company","gridOptions","$location",function(a,b,c,d,e,f,g,h,i,j){a.initView=function(){var b={exporterCsvFilename:"Companies.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",name:"profile",href:"/contactmanager/companies/view/{{row.entity.id}}/settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(h,b,a)},a.create=function(){var a=f.open({animation:!0,templateUrl:"app/contactmanager/company/list/create.modal.html",controller:"CompanyListCreateModalCtrl"});a.result.then(function(a){b.post("/api/contactmanager/companies",a).then(function(a){j.path("/contactmanager/companies/view/"+a.id+"/settings")})["catch"](function(a){d.show(a.data.message,"danger")})},function(){g.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.companies.list",{url:"/list",templateUrl:"app/contactmanager/company/list/list.html",controller:"ContactManagerCompanyListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("ContactManagerCompanyViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location",function(a,b,c,d,e,f){a.getCompany=function(){b.get("/api/contactmanager/companies/"+e.id).success(function(b){a.company=b}).error(function(a){f.path("/contactmanager/companies/list")})},a.updateCompany=function(){var f=angular.copy(a.company);b.put("/api/contactmanager/companies/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(b){c.show(d.instant(b.message),"danger"),a.company=f})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.companies.view",{url:"/view/:id",templateUrl:"app/contactmanager/company/view/view.html",controller:"ContactManagerCompanyViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.contactmanager.companies.view.settings",{url:"/settings",templateUrl:"app/contactmanager/company/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("Contact",["$resource",function(a){return a("/api/contactmanager/contacts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.contacts",{url:"/contacts",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ContactManagerListImportModalCtrl",["$scope","$uibModalInstance","indexes","csv","xAlert","socket","Service","Contact","$translate",function(a,b,c,d,e,f,g,h,i){function j(b){if(b>=a.csvLength||a.stopped)return void(a.importing=!1);var c={Phones:[],Emails:[],customFields:{}};return _.forOwn(a.item,function(e,f){switch(f){case"tags":c.tags=[],a.item.tags.forEach(function(a){""!==d[b][a]&&c.tags.push(d[b][a])});break;default:c[f]=d[b][e]}}),c.tags=c.tags?c.tags.join(","):void 0,c.ServiceId=a.item.ServiceId,c.CompanyId=a.item.CompanyId||null,h.save(c).$promise.then(function(c){a["import"].success+=k,a["import"].succeeded+=1,j(b+1)})["catch"](function(c){a["import"].fail+=k,a["import"].failed+=1,j(b+1)})}a.indexes=c,a.importing=!1,a.submitted=!1,a.stopped=!1,a["import"]={success:0,fail:0,succeeded:0,failed:0},a.csvLength=d.length;var k=100/a.csvLength;a.forms={dashboard:void 0},a.item={},a.start=function(){a.importing=!0,a.submitted=!0,j(0)},a.getServices=function(){return g.get().$promise.then(function(b){a.services=b.rows,a.item.ServiceId=1,a.getCustomFields()})["catch"](function(a){e.show(i.instant(a.message)+"!","danger")})},a.getCustomFields=function(){return g.get({serviceId:a.item.ServiceId,controller:"customfields"}).$promise.then(function(b){b.rows.forEach(function(a){a.values=JSON.parse(a.values)}),a.customFields=b.rows,f.socket.on("custom_field:remove",function(b){_.remove(a.customFields,function(a){return b.id==a.id})}),f.socket.on("custom_field:save",function(b){if(b.ServiceId===a.item.ServiceId){var c=_.find(a.customFields,{id:b.id});c||("string"==typeof b.values&&(b.values=JSON.parse(b.values)),a.customFields.push(b))}})})["catch"](function(a){console.error(a),e.show(a.message,"danger")})},a.close=function(){b.close()},a.stop=function(){a.stopped=!0}}]),angular.module("xCallyShuttleApp").controller("ContactManagerContactListCtrl",["$scope","$translate","Modal","FileUploader","Papa","$uibModal","$log","Contact","gridOptions","Service","uiGridConstants","xAlert","socket",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.initView=function(){return j.get().$promise.then(function(b){a.services=[],b.rows.forEach(function(b,c){a.services.push({value:b.id,label:b.name})})}).then(function(){var b={exporterCsvFilename:"Contacts.csv",columnDefs:[{name:"firstName"},{name:"lastName"},{name:"phone"},{name:"mobile"},{name:"email"},{name:"ServiceId",displayName:"APPLICATION_SERVICE",field:"Service.name",filter:{type:k.filter.SELECT,selectOptions:a.services}},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",name:"profile",onClick:"grid.appScope.openContactTab(row.entity)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.fullname, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(h,b,a)})["catch"](function(a){l.show(b.instant(a.message)+"!","danger")})},d.FileSelect.prototype.isEmptyAfterSelection=function(){return!0};var n=a.uploader=new d({queueLimit:1,clearInputAfterAddedToQueue:!0});n.onAfterAddingFile=function(b){console.log("fileadded"),e.parse(b._file,{header:!0,complete:function(b){a.uploader.clearQueue(),a["import"](b.data)},error:function(a){console.log(a)}})},a["import"]=function(b){var c=f.open({animation:!0,size:"lg",backdrop:"static",keyboard:!1,templateUrl:"app/contactmanager/contact/list/import.modal.html",controller:"ContactManagerListImportModalCtrl",resolve:{indexes:function(){return _.keys(b[0])},csv:function(){return b}}});c.result.then(function(b){a.gridOptions.getPage()},function(){g.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.contacts.list",{url:"/list",templateUrl:"app/contactmanager/contact/list/list.html",controller:"ContactManagerContactListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager",{url:"/contactmanager",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("ContactManagerServiceListCreateModalCtrl",["$scope","$uibModalInstance",function(a,b){a.forms={dashboard:void 0},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ContactManagerServiceListCtrl",["$scope","$http","$translate","Modal","xAlert","$uibModal","$log","Service","gridOptions",function(a,b,c,d,e,f,g,h,i){a.initView=function(){var b={exporterCsvFilename:"Services.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",name:"settings",href:"/contactmanager/services/view/{{row.entity.id}}/settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(h,b,a)},a.create=function(){var d=f.open({animation:!0,templateUrl:"app/contactmanager/service/list/create.modal.html",controller:"ContactManagerServiceListCreateModalCtrl"});d.result.then(function(d){b.post("/api/contactmanager/services/",d).then(function(b){a.gridOptions.getPage(),e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})},function(){g.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.services.list",{url:"/list",templateUrl:"app/contactmanager/service/list/list.html",controller:"ContactManagerServiceListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Service",["$resource",function(a){return a("/api/contactmanager/services/:serviceId/:controller/:id",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.services",{url:"/services",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ContactManagerServiceCustomFieldViewCreateModalCtrl",["$scope","$uibModalInstance","$translate",function(a,b,c){a.$translate=c,a.forms={dashboard:void 0},a.item={},a.choices=[{value:""}],a.addField=function(){a.choices.push({})},a.removeField=function(b){a.choices.splice(b,1)},a.types=[{name:"APPLICATION_TEXT",value:"text"},{name:"APPLICATION_SELECT",value:"select"}],a.ok=function(){"select"===a.item.type&&(a.item.values=angular.toJson(a.choices)),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ContactManagerServiceViewCtrl",["$scope","xAlert","$translate","$stateParams","socket","$location","$uibModal","$log","Modal","Service","Team","gridOptions",function(a,b,c,d,e,f,g,h,i,j,k,l){var m=function(){return{select:function(b){return j.save({serviceId:a.service.id,controller:"agents"},{agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})},deselect:function(b){return j["delete"]({serviceId:a.service.id,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})}}};a.getService=function(){return j.get({serviceId:d.id}).$promise.then(function(b){a.service=b})["catch"](function(a){f.path("/contactmanager/services/list")})},a.updateService=function(){return j.update({serviceId:d.id},a.service).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.getTeams=function(){return k.get().$promise.then(function(b){return a.teams=b.rows,j.query({serviceId:d.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindQueue(a.teams,_.map(b,function(a){return{id:a.id}}),m)})["catch"](function(a){console.error(a)})},a.initCustomFields=function(){var b={exporterCsvFilename:"customfields.csv",primaryKey:"id",columnDefs:[{name:"alias",displayName:"APPLICATION_NAME"},{name:"type"},{name:"description"},{name:"action",width:200,buttons:[{"class":"blue-hoki",href:"/contactmanager/services/view/{{grid.appScope.$stateParams.id}}/customfields/settings/{{row.entity.id}}",name:"settings"},{"class":"red-sunglo",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)",name:"delete"}]}]};a.gridOptions=l.gridOptions(j,b,a,{serviceId:d.id,controller:"customfields"})},a.create=function(){var e=g.open({animation:!0,templateUrl:"app/contactmanager/service/view/create.modal.html",controller:"ContactManagerServiceCustomFieldViewCreateModalCtrl"});e.result.then(function(e){return j.save({serviceId:d.id,controller:"customfields"},e).$promise.then(function(d){a.gridOptions.getPage(),b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message||a.data.message,"danger")})},function(){h.info("Modal dismissed at: "+new Date)})},a.getCustomField=function(){return j.get({serviceId:d.id,controller:"customfields",id:d.cfId}).$promise.then(function(b){console.log(b),a.customField=b,"select"===a.customField.type&&(a.choices=JSON.parse(a.customField.values))})["catch"](function(a){console.error(a),f.path("/contactmanager/customfields/list")})},a.updateCustomField=function(){var e=angular.copy(a.customField);return"select"===e.type&&(e.values=angular.toJson(a.choices)),j.update({serviceId:d.id,controller:"customfields",id:d.cfId},e).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.addField=function(){a.choices.push({})},a.removeField=function(b){a.choices.splice(b,1)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.services.view",{url:"/view/:id",templateUrl:"app/contactmanager/service/view/view.html",controller:"ContactManagerServiceViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.contactmanager.services.view.settings",{url:"/settings",templateUrl:"app/contactmanager/service/view/view.settings.html"}).state("main.contactmanager.services.view.agents",{url:"/agents",templateUrl:"app/contactmanager/service/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}}).state("main.contactmanager.services.view.customfields",{url:"/customfields",templateUrl:"app/contactmanager/service/view/view.customFields.html"}).state("main.contactmanager.services.view.customfields.settings",{url:"/settings/:cfId",templateUrl:"app/contactmanager/service/view/view.customFieldSettings.html",controller:"ContactManagerServiceViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("DashboardCtrl",["$scope","$translate",function(a,b){a.voice=[{name:b.instant("APPLICATION_QUEUE"),link:"main.dashboard.voice"}],a.mail=[{name:b.instant("APPLICATION_QUEUE"),link:"main.dashboard.mail"}]}]),angular.module("xCallyShuttleApp").factory("Dashboard",["$resource",function(a){return a("/api/dashboards/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.dashboard",{"abstract":!0,url:"/dashboard",templateUrl:"app/dashboard/dashboard.html",controller:"DashboardCtrl"}).state("main.dashboard.voice",{url:"/voice",controller:"DashboardVoiceCtrl",templateUrl:"app/dashboard/voice/voice.html"}).state("main.dashboard.mail",{url:"/mail",controller:"DashboardMailCtrl",templateUrl:"app/dashboard/mail/mail.html"})}]),angular.module("xCallyShuttleApp").controller("DashboardMailCtrl",["$scope",function(a){a.message="Hello"}]),angular.module("xCallyShuttleApp").controller("DashboardVoiceCtrl",["$scope","Auth","ReportQueue","ReportCall","socket",function(a,b,c,d,e){a.Auth=b,a.initWaiting=function(){return c.get({id:"waiting"}).$promise.then(function(b){a.waiting=b.value,e.socket.on("dashboard:waiting",function(b){a.waiting=b.value})})["catch"](function(a){console.error(a)})},a.initActive=function(){return c.get({id:"active"}).$promise.then(function(b){a.active=b.value,e.socket.on("dashboard:active",function(b){a.active=b.value})})["catch"](function(a){console.error(a)})},a.initAnswered=function(){return c.get({id:"answered"}).$promise.then(function(b){a.answered=b.value,e.socket.on("dashboard:answered",function(b){a.answered=b.value})})["catch"](function(a){console.error(a)})},a.initAbandoned=function(){return c.get({id:"abandoned"}).$promise.then(function(b){a.abandoned=b.value,e.socket.on("dashboard:abandoned",function(b){a.abandoned=b.value})})["catch"](function(a){console.error(a)})},a.initAvgAnswerTime=function(){return c.get({id:"avganswertime"}).$promise.then(function(b){a.avganswertime=b.value,e.socket.on("dashboard:avganswertime",function(b){a.avganswertime=b.value})})["catch"](function(a){console.error(a)})},a.initAvgTalkTime=function(){return c.get({id:"avgtalktime"}).$promise.then(function(b){a.avgtalktime=b.value,e.socket.on("dashboard:avgtalktime",function(b){a.avgtalktime=b.value})})["catch"](function(a){console.error(a)})},a.initAnswerRate=function(){return c.get({id:"answerrate"}).$promise.then(function(b){a.answerrate=b.value,e.socket.on("dashboard:answerrate",function(b){a.answerrate=b.value})})["catch"](function(a){console.error(a)})},a.initTotalOffered=function(){return c.get({id:"totaloffered"}).$promise.then(function(b){a.totaloffered=b.value,e.socket.on("dashboard:totaloffered",function(b){a.totaloffered=b.value})})["catch"](function(a){console.error(a)})},a.initUnmanaged=function(){return c.get({id:"unmanaged"}).$promise.then(function(b){a.unmanaged=b.value,e.socket.on("dashboard:unmanaged",function(b){a.unmanaged=b.value})})["catch"](function(a){console.error(a)})},a.initAbandonRate=function(){return c.get({id:"abandonrate"}).$promise.then(function(b){a.abandonrate=b.value,e.socket.on("dashboard:abandonrate",function(b){a.abandonrate=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutbound=function(){return d.get({id:"manualoutbound"}).$promise.then(function(b){a.manualoutbound=b.value,e.socket.on("dashboard:manualoutbound",function(b){a.manualoutbound=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutboundGlobalDuration=function(){return d.get({id:"manualoutboundglobalduration"}).$promise.then(function(b){a.manualoutboundglobalduration=b.value,e.socket.on("dashboard:manualoutboundglobalduration",function(b){a.manualoutboundglobalduration=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutboundAvgDuration=function(){return d.get({id:"manualoutboundavgduration"}).$promise.then(function(b){a.manualoutboundavgduration=b.value,e.socket.on("dashboard:manualoutboundavgduration",function(b){a.manualoutboundavgduration=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutboundAnswered=function(){return d.get({id:"manualoutboundanswered"}).$promise.then(function(b){a.manualoutboundanswered=b.value,e.socket.on("dashboard:manualoutboundanswered",function(b){a.manualoutboundanswered=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutboundAnswerRate=function(){return d.get({id:"manualoutboundanswerrate"}).$promise.then(function(b){a.manualoutboundanswerrate=b.value,e.socket.on("dashboard:manualoutboundanswerrate",function(b){a.manualoutboundanswerrate=b.value})})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.desk",{url:"/desk",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("DeskAccount",["$resource",function(a){return a("/api/desk/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("DeskListCtrl",["$scope","$http","$rootScope","xAlert","$translate","socket","Modal","stResource",function(a,b,c,d,e,f,g,h){a.conf={accountsByPage:{name:"10",value:10}},a.accountsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.accounts={checked:[]},a.check=function(b,c){c?a.accounts.checked=angular.copy(_.map(a.displayedDeskAccounts,"id")):a.accounts.checked=[]},a.getAccounts=function(b){return _.map(a.displayedDeskAccounts,function(a){var c={};return b.forEach(function(b){c[b]=a[b]}),c})},a.initList=function(b){f.unsyncUpdates("desk_account"),b.url="/api/desk/accounts",h.getPage(b).then(function(d){a.displayedDeskAccounts=d.rows,b.pagination.numberOfPages=d.total_pages,c.updateTableConfig(a.accountsByPage,a.displayedDeskAccounts.length),c.updateTableConfig(a.conf.accountsByPage,a.displayedDeskAccounts.length)}),f.socket.on("desk_account:save",function(){a.initList(b)}),f.socket.on("desk_account:remove",function(c){a.accounts.checked=_.without(a.accounts.checked,c.id),a.initList(b)})},a.deleteItem=g.confirm["delete"](function(a){b["delete"]("/api/desk/accounts/"+a).success(function(){d.show(e.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.deleteItems=g.confirm["delete"](function(){b["delete"]("/api/desk/accounts",{params:{id:a.accounts.checked}}).success(function(){d.show(e.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.checkAccount=function(a){b.get("/api/desk/accounts/"+a+"/check").then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.desk.list",{url:"/list",templateUrl:"app/desk/list/list.html",controller:"DeskListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("DeskViewCtrl",["$scope","$http","$stateParams","$translate","$location","WizardHandler","socket","xAlert","Modal","desk_com",function(a,b,c,d,e,f,g,h,i,j){a.$stateParams=c,a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:500,scrollInertia:0},a.initConfiguration=function(){a.formsConfiguration={},a.configuration={}},a.goNext=function(){f.wizard().next()},a.formValidation=function(a){return a},a.$on("$destroy",function(){g.unsyncUpdates("desk_configuration"),g.unsyncUpdates("desk_field")}),a.initView=function(){b.get("/api/desk/accounts/"+c.id).success(function(b){a.account=b}).error(function(a){h.show(a.message,"danger")})},a.updateItem=function(){b.put("/api/desk/accounts/"+c.id,a.account).success(function(){h.show(d.instant("MESSAGE_WELL_DONE")+".","success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getConfigurations=function(){b.get("/api/desk/configurations",{params:{AccountId:c.id}}).success(function(b){a.configurations=b,g.socket.on("desk_configuration:remove",function(b){_.remove(a.configurations,{id:b.id})})}).error(function(a){h.show(a.message,"danger")})},a.deleteConfiguration=i.confirm["delete"](function(a){b["delete"]("api/desk/configurations/"+a).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.createConfiguration=function(){a.configuration.AccountId=c.id,b.post("api/desk/configurations",a.configuration).success(function(a){e.path("desk/view/"+c.id+"/configurations/settings/"+a.id)}).error(function(){h.show("Something went wrong!","danger")})},a.fieldType=["string","variable"],a.descFieldType=["string","key_value"],a.getFields=function(){b.get("/api/desk/accounts/"+c.id+"/fields").success(function(b){a.accountFields=j.fields.concat(b)}).error(function(a){h.show(a.message,"danger")})},a.getConfiguration=function(){b.get("/api/desk/configurations/"+c.configurationId).success(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,g.socket.on("desk_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})}).error(function(a){h.show(a.message,"danger")})},a.getVariables=function(){b.get("/api/variables").success(function(b){a.variables=b.rows}).error(function(a){h.show(a.message,"danger")})},a.removeItem=function(a){b["delete"]("api/desk/fields/"+a.id).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.addItemSubject=function(){var d={type:"string",content:""};b.post("/api/desk/configurations/"+c.configurationId+"/subject",d).success(function(b){a.subjectConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.addItemDescription=function(){var d={type:"string",content:""};b.post("/api/desk/configurations/"+c.configurationId+"/description",d).success(function(b){a.descriptionConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.addItemField=function(){var d={content:""};b.post("/api/desk/configurations/"+c.configurationId+"/field",d).success(function(b){a.fieldConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.updateField=function(a){b.put("/api/desk/fields/"+a.id,a).success(function(){}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.changeType=function(b){"variable"===b.type?b.content="":"string"===b.type&&(b.VariableId=null),a.updateField(b)},a.changeDescType=function(b){"key_value"===b.type?(b.content="","string"===b.keyType?b.VariableId=null:"variable"===b.keyType&&(b.keyContent="")):"string"===b.type&&(b.VariableId=null,b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){if(b.content="",b.idField){var c=_.find(a.accountFields,"id",b.idField);c&&(b.customField=_.result(c,"custom",!0))}a.updateField(b)},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"id",b);return c?c.data.choices?c.data.choices:null:void 0}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.desk.view",{url:"/view/:id",templateUrl:"app/desk/view/view.html",controller:"DeskViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.desk.view.account",{url:"/account",templateUrl:"app/desk/view/view.account.html"}).state("main.desk.view.configurations",{url:"/configurations",templateUrl:"app/desk/view/view.configurations.html"}).state("main.desk.view.configurations.settings",{url:"/settings/:configurationId",templateUrl:"app/desk/view/view.configurationSettings.html",controller:"DeskViewCtrl"}).state("main.desk.view.configuration",{url:"/configuration",templateUrl:"app/desk/view/view.configuration.html"})}]),angular.module("xCallyShuttleApp").controller("DeskWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={}},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){console.log(a.item),b.post("api/desk/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/desk/list")}).error(function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.desk.wizard",{url:"/wizard",templateUrl:"app/desk/wizard/wizard.html",controller:"DeskWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.freshdesk",{url:"/freshdesk",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("FreshdeskAccount",["$resource",function(a){return a("/api/freshdesk/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("FreshdeskListCtrl",["$scope","$http","$rootScope","xAlert","$translate","socket","Modal","stResource",function(a,b,c,d,e,f,g,h){a.conf={accountsByPage:{name:"10",value:10}},a.accountsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.accounts={checked:[]},a.check=function(b,c){c?a.accounts.checked=angular.copy(_.map(a.displayedFreshdeskAccounts,"id")):a.accounts.checked=[]},a.getAccounts=function(b){return _.map(a.displayedFreshdeskAccounts,function(a){var c={};return b.forEach(function(b){c[b]=a[b]}),c})},a.initList=function(b){f.unsyncUpdates("freshdesk_account"),b.url="/api/freshdesk/accounts",h.getPage(b).then(function(d){a.displayedFreshdeskAccounts=d.rows,b.pagination.numberOfPages=d.total_pages,c.updateTableConfig(a.accountsByPage,a.displayedFreshdeskAccounts.length),c.updateTableConfig(a.conf.accountsByPage,a.displayedFreshdeskAccounts.length)}),f.socket.on("freshdesk_account:save",function(){a.initList(b)}),f.socket.on("freshdesk_account:remove",function(c){a.accounts.checked=_.without(a.accounts.checked,c.id),a.initList(b)})},a.deleteItem=g.confirm["delete"](function(a){b["delete"]("/api/freshdesk/accounts/"+a).success(function(){d.show(e.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.deleteItems=g.confirm["delete"](function(){b["delete"]("/api/freshdesk/accounts",{params:{id:a.accounts.checked}}).success(function(){d.show(e.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.checkAccount=function(a){b.get("/api/freshdesk/accounts/"+a+"/check").then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.freshdesk.list",{url:"/list",templateUrl:"app/freshdesk/list/list.html",controller:"FreshdeskListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("FreshdeskViewCtrl",["$scope","$http","$stateParams","$translate","$location","$filter","WizardHandler","socket","xAlert","Modal",function(a,b,c,d,e,f,g,h,i,j){a.$stateParams=c,a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:500,scrollInertia:0},a.initConfiguration=function(){a.formsConfiguration={},a.configuration={}},a.goNext=function(){g.wizard().next()},a.formValidation=function(a){return a},a.$on("$destroy",function(){h.unsyncUpdates("freshdesk_configuration"),h.unsyncUpdates("freshdesk_field")}),a.initView=function(){b.get("/api/freshdesk/accounts/"+c.id).success(function(b){a.account=b}).error(function(a){i.show(a.message,"danger")})},a.updateItem=function(){b.put("/api/freshdesk/accounts/"+c.id,a.account).success(function(){i.show(d.instant("MESSAGE_WELL_DONE")+".","success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getConfigurations=function(){b.get("/api/freshdesk/configurations",{params:{AccountId:c.id}}).success(function(b){a.configurations=b,h.socket.on("freshdesk_configuration:remove",function(b){_.remove(a.configurations,{id:b.id})})}).error(function(a){i.show(a.message,"danger")})},a.deleteConfiguration=j.confirm["delete"](function(a){b["delete"]("api/freshdesk/configurations/"+a).success(function(){i.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.createConfiguration=function(){a.configuration.AccountId=c.id,b.post("api/freshdesk/configurations",a.configuration).success(function(a){e.path("freshdesk/view/"+c.id+"/configurations/settings/"+a.id)}).error(function(){i.show("Something went wrong!","danger")})},a.fieldType=["string","variable"],a.descFieldType=["string","key_value"],a.getFields=function(){b.get("/api/freshdesk/accounts/"+c.id+"/fields").success(function(b){a.accountFields=[],b=f("freshdesk")(b),_.forEach(b,function(b){ +a.accountFields.push(b.ticket_field)})}).error(function(a){i.show(a.message,"danger")})},a.getConfiguration=function(){b.get("/api/freshdesk/configurations/"+c.configurationId).success(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,h.socket.on("freshdesk_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})}).error(function(a){i.show(a.message,"danger")})},a.getVariables=function(){b.get("/api/variables").success(function(b){a.variables=b.rows}).error(function(a){i.show(a.message,"danger")})},a.removeItem=function(a){b["delete"]("api/freshdesk/fields/"+a.id).success(function(){i.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.addItemSubject=function(){var d={type:"string",content:""};b.post("/api/freshdesk/configurations/"+c.configurationId+"/subject",d).success(function(b){a.subjectConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.addItemDescription=function(){var d={type:"string",content:""};b.post("/api/freshdesk/configurations/"+c.configurationId+"/description",d).success(function(b){a.descriptionConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.addItemField=function(){var d={content:""};b.post("/api/freshdesk/configurations/"+c.configurationId+"/field",d).success(function(b){a.fieldConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.updateField=function(a){b.put("/api/freshdesk/fields/"+a.id,a).success(function(){}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.changeType=function(b){"variable"===b.type?b.content="":"string"===b.type&&(b.VariableId=null),a.updateField(b)},a.changeDescType=function(b){"key_value"===b.type?(b.content="","string"===b.keyType?b.VariableId=null:"variable"===b.keyType&&(b.keyContent="")):"string"===b.type&&(b.VariableId=null,b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){if(b.content="",b.idField){var c=_.find(a.accountFields,"name",b.idField);c&&(b.customField=!_.result(c,"default",!0))}a.updateField(b)},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"name",b);return c?c.choices.length>0?c.choices:null:void 0}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.freshdesk.view",{url:"/view/:id",templateUrl:"app/freshdesk/view/view.html",controller:"FreshdeskViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.freshdesk.view.account",{url:"/account",templateUrl:"app/freshdesk/view/view.account.html"}).state("main.freshdesk.view.configurations",{url:"/configurations",templateUrl:"app/freshdesk/view/view.configurations.html"}).state("main.freshdesk.view.configurations.settings",{url:"/settings/:configurationId",templateUrl:"app/freshdesk/view/view.configurationSettings.html",controller:"FreshdeskViewCtrl"}).state("main.freshdesk.view.configuration",{url:"/configuration",templateUrl:"app/freshdesk/view/view.configuration.html"})}]),angular.module("xCallyShuttleApp").controller("FreshdeskWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={}},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){console.log(a.item),b.post("api/freshdesk/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/freshdesk/list")}).error(function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.freshdesk.wizard",{url:"/wizard",templateUrl:"app/freshdesk/wizard/wizard.html",controller:"FreshdeskWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.integrations",{url:"/integrations",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("Integration",["$resource",function(a){return a("/api/integrations/:id/:controller",{id:"@id"})}]),angular.module("xCallyShuttleApp").controller("IntegrationListCtrl",["$scope","Modal","socket","FileUploader","Integration","xAlert",function(a,b,c,d,e,f){a.integrationsByPage=10;var g=a.uploader=new d({url:"api/integrations",autoUpload:!0,removeAfterUpload:!0});g.filters.push({name:"zipFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|zip|".indexOf(b)}}),g.onSuccessItem=function(a,b,c,d){console.info("onSuccessItem",a,b,c,d),f.show(b.name,"success")},g.onErrorItem=function(a,b,c,d){console.info("onErrorItem",a,b,c,d),b.errors.forEach(function(a){f.show(a.message,"danger")})},a.deleteItem=b.confirm["delete"](function(a){e["delete"]({id:a},function(){f.show("Integration Removed","success")},function(a){f.show(a.data.errors,"danger")})}),a.initList=function(){a.integrations=e.query({},function(a){c.syncUpdates("integration",a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.integrations.list",{url:"/list",templateUrl:"app/integration/list/list.html",controller:"IntegrationListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js"]})}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty",{url:"/jscripty",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("JscriptyProject",["$resource",function(a){return a("/api/jscripty/projects/:id/:controller/:action/:action2",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("JscriptyProjectListCtrl",["$scope","$uibModal","JscriptyProject","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"jscriptyProjects.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:300,buttons:[{"class":"blue-hoki",href:"/jscripty/projects/view/{{row.entity.id}}",name:"settings"},{"class":"green",name:"start",onClick:"grid.appScope.openJscriptyTab(row.entity)"},{"class":"purple",href:"/jscripty/projects/report/{{row.entity.id}}/sessions",name:"report"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/jscripty/project/list/list.create.modal.html",controller:"JscriptyProjectListCreateCtrl"});c.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("JscriptyProjectListCreateCtrl",["$scope","$translate","$uibModalInstance","JscriptyProject","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){console.log(a),e.show(b.instant(a.data.translatedMessage),"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty.projects.list",{url:"/list",templateUrl:"app/jscripty/project/list/list.html",controller:"JscriptyProjectListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty.projects",{url:"/projects",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("JscriptyProjectReportCtrl",["$scope","$http","$state","$stateParams","socket","Auth","Modal","xAlert","$translate","$rootScope","gridOptions","JscriptyProject","$location",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.projectStats={started:0,incomplete:0,completed:0},a.projectId=d.id,a.initView=function(){return l.get({id:d.id,controller:"sessions"}).$promise.then(function(b){a.projectId=d.id,console.log(a.projectId);var c=_.groupBy(b.rows,"status");a.projectStats.started=c.started?c.started.length:0,a.projectStats.completed=c.completed?c.completed.length:0,a.projectStats.incomplete=c.incomplete?c.incomplete.length:0})["catch"](function(a){h.show(a.message,"danger")})},a.getProjectSessions=function(){var b={exporterCsvFilename:"jscriptyProjects.csv",columnDefs:[{name:"projectId",displayName:"APPLICATION_PROJECTID"},{name:"session_id",displayName:"APPLICATION_SESSIONID"},{name:"createdAt",displayName:"APPLICATION_STARTEDAT"},{name:"completedAt",displayName:"APPLICATION_COMPLETEDAT"},{name:"status",displayName:"APPLICATION_STATUS"},{name:"last_question_id",displayName:"APPLICATION_LASTQUESTIONID"},{name:"action",width:100,buttons:[{"class":"blue-hoki",href:"/jscripty/projects/report/{{row.entity.projectId}}/session/{{row.entity.session_id}}",name:"Detail"}]}]};a.gridOptions=k.gridOptions(l,b,a,{id:d.id,controller:"sessions"})},a.getSessionDetails=function(){console.log(d.sessionId),b.get("/api/jscripty/projects/"+d.id+"/sessions/"+d.sessionId).success(function(b){a.sessionQuestions=b[0],console.log("session",a.sessionQuestions)})["catch"](function(a){h.show(a.message,"danger")})},a.getQuestionSummary=function(){var b={exporterCsvFilename:"jscriptyProjects.csv",columnDefs:[{name:"question_id",width:150,displayName:"APPLICATION_QUESTIONID"},{name:"question_type",width:150,displayName:"APPLICATION_QUESTIONTYPE"},{name:"question_label",width:200,displayName:"APPLICATION_QUESTIONLABEL"},{name:"question_text",displayName:"APPLICATION_QUESTION"},{name:"count",width:100,displayName:"APPLICATION_COUNT"}]};a.gridOptions=k.gridOptions(l,b,a,{id:d.id,controller:"questions",action:"summary"})},a.getQuestionDetail=function(){b.get("/api/jscripty/projects/"+d.id+"/questions/detail").success(function(b){var c=_.groupBy(b,"question_id");_.forEach(c,function(a,b){c[b]=_.groupBy(a,"question_label"),_.forEach(c[b],function(a,d){c[b][d]=_.groupBy(a,"question_text")})}),a.questionDetail=c,console.log("detail",a.questionDetail)})["catch"](function(a){h.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty.projects.report",{url:"/report/:id",templateUrl:"app/jscripty/project/report/report.html",controller:"JscriptyProjectReportCtrl"}).state("main.jscripty.projects.report.sessions",{url:"/sessions",templateUrl:"app/jscripty/project/report/report.sessions.html"}).state("main.jscripty.projects.report.summary",{url:"/summary",templateUrl:"app/jscripty/project/report/report.summary.html"}).state("main.jscripty.projects.report.detail",{url:"/detail",templateUrl:"app/jscripty/project/report/report.detail.html"}).state("main.jscripty.projects.report.sessionDetail",{url:"/session/:sessionId",controller:"JscriptyProjectReportCtrl",templateUrl:"app/jscripty/project/report/report.session.detail.html"})}]),angular.module("xCallyShuttleApp").controller("JscriptyProjectViewCtrl",["$scope","$http","$state","$stateParams","socket","Auth","Modal","xAlert","$translate","$rootScope",function(a,b,c,d,e,f,g,h,i,j){a.jscriptyProject={},a.getProject=function(){b.get("/api/jscripty/projects/"+d.id).success(function(b){a.jscriptyProject=b,angular.element(document).ready(function(){window.onerror=function(a,b,c){try{if(null!=a&&-1!=a.indexOf("Script error."));else{var d=new Image;d.src="assets/plugins/mxgraph/images/1x1.png?msg="+encodeURIComponent(a)+"&url="+encodeURIComponent(b)+"&lnum="+encodeURIComponent(c)}}catch(e){}},b.token=f.getToken();var a=new EditorUi(new Editor);a.openString(b.draft,b.name,b),a.editor.graphChangeListener=function(a,b){var c=b.properties.rtChange||!1;c||(this.modified=!0)}}),e.syncUpdates("jscripty_project",[b],function(a,c,d){c.id===b.id})})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty.projects.view",{url:"/view/:id",templateUrl:"app/jscripty/project/view/view.html",controller:"JscriptyProjectViewCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",serie:!0,cache:!1,files:["assets/plugins/mxgraph/css/common.css","assets/plugins/mxgraph/css/explorer.css","assets/plugins/mxgraph/styles/grapheditor.css","assets/plugins/mxgraph/styles/custom.css","assets/plugins/jscripty/js/custom.js","assets/plugins/mxgraph/js/mxClient.js","assets/plugins/jscripty/js/Editor.js","assets/plugins/jscripty/js/Graph.js","assets/plugins/jscripty/js/EditorUi.js","assets/plugins/jscripty/js/Actions.js","assets/plugins/jscripty/js/Menus.js","assets/plugins/jscripty/js/Sidebar.js","assets/plugins/jscripty/js/Toolbar.js","assets/plugins/jscripty/js/Dialogs.js"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("LoginCtrl",["$scope","Auth","$location","$window","$rootScope",function(a,b,c,d,e){a.year=moment().year(),a.userLogin={},a.userSignUp={},a.loginSubmitted=!1,a.signupSubmitted=!1,a.errorLogin=!1,a.errorSignup=!1,a.errorLog="",a.flagLogin1=!1,a.toogleLogin=function(){a.flagLogin1=!a.flagLogin1},e.bodyLayout="login",a.$on("$viewContentLoaded",function(){Metronic.init(),Layout.init()}),a.login=function(d){a.loginSubmitted=!0,d.$valid?b.login({name:a.userLogin.name,password:a.userLogin.password,remember:a.userLogin.remember}).then(function(){c.path("/dashboard/voice")})["catch"](function(b){a.errorLog=b.message,a.errorLogin=!0}):a.errorLogin=!0},a.signup=function(d){a.signupSubmitted=!0,d.$valid?b.createUser({email:a.userSignUp.email,fullname:a.userSignUp.fullname,name:a.userSignUp.name,password:a.userSignUp.password,role:a.userSignUp.role,online:!0}).then(function(){c.path("/")})["catch"](function(b){a.errorLog=b.message,a.errorSignup=!0}):a.errorSignup=!0},a.loginOauth=function(a){d.location.href="/auth/"+a}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("login",{url:"/login",templateUrl:"app/login/login.html",controller:"LoginCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/login.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Action",["$resource",function(a){return a("/api/actions/:name/:controller",{name:"@name"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").directive("actionBuilderTemplate",["$compile","xAlert","$http","$timeout","Template","$translate",function(a,b,c,d,e,f){return{restrict:"E",scope:{element:"=",form:"="},templateUrl:"app/main/template/actionBuilder/template.actionBuilderTemplate.html",compile:function(c,g){var h,i;return h=c.contents().remove(),function(c,g,j){function k(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")}c.randomName=k(),d(function(){return e.get().$promise.then(function(a){c.templates=a.rows})["catch"](function(a){b.show(f.instant(a.message),"danger")})}),i||(i=a(h)),g.append(i(c,function(a){return a}))}}}}]).directive("actionBuilderIntegration",["$compile","xAlert","$http","$timeout","Integration","$translate","ZendeskAccount","DeskAccount","SalesforceAccount","FreshdeskAccount","SugarcrmAccount",function(a,b,c,d,e,f,g,h,i,j,k){return{restrict:"E",scope:{element:"=",form:"="},templateUrl:"app/main/template/actionBuilder/template.actionBuilderIntegration.html",compile:function(c,l){var m,n;return m=c.contents().remove(),function(c,l,o){function p(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")}c.randomName=p(),d(function(){return e.get({active:1}).$promise.then(function(a){c.integrations=a.rows,c.element.data1&&q()})["catch"](function(a){b.show(f.instant(a.message),"danger")})});var q=function(){var a;switch(c.element.data1){case"zendesk":a=g;break;case"desk":a=h;break;case"salesforce":a=i;break;case"freshdesk":a=j;break;case"sugarcrm":a=k}return a.get().$promise.then(function(a){c.accounts=a.rows,c.element.data2&&r()})["catch"](function(a){b.show(f.instant(a.message),"danger")})},r=function(){c.configurations=_.find(c.accounts,{id:Number(c.element.data2)}).Configurations};c.changeIntegration=function(){c.element.data2="",q()},c.changeAccount=function(){c.element.data3="",r()},n||(n=a(m)),l.append(n(c,function(a){return a}))}}}}]).directive("actionBuilderStatus",["$compile","xAlert","$http","$timeout","$translate",function(a,b,c,d,e){return{restrict:"E",scope:{element:"=",form:"="},templateUrl:"app/main/template/actionBuilder/template.actionBuilderStatus.html",compile:function(b,c){var d,e;return d=b.contents().remove(),function(b,c,f){function g(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")}b.randomName=g(),b.states=[{name:"APPLICATION_STATUS_NEW",value:"NEW"},{name:"APPLICATION_STATUS_OPEN",value:"OPEN"},{name:"APPLICATION_STATUS_CLOSED",value:"CLOSED"}],e||(e=a(d)),c.append(e(b,function(a){return a}))}}}}]),angular.module("xCallyShuttleApp").factory("Ami",["$resource",function(a){return a("/api/ami/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("ChooseContactModalCtrl",["$scope","$uibModalInstance","eventId","$http","xAlert","$translate",function(a,b,c,d,e,f){a.open=function(a){b.close(a)},a.getContacts=function(){d.get("/api/contactmanager/contacts/"+c+"/checkevent").success(function(b){a.contacts=b}).error(function(a){e.show(f.instant(a.message)+"!","danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("CloseEditedTabModalCtrl",["$scope","$uibModalInstance",function(a,b){a.close=function(){b.close()},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").factory("gridOptions",["Modal","xAlert","$translate","$interval","$q","usSpinnerService",function(a,b,c,d,e,f){return{gridOptions:function(d,g,h,i,j,k){h.id=[];var l=k?"gridOptions"+k:"gridOptions",m={offset:0,limit:10};g.draggable&&(g.rowTemplate='
',g.useExternalPagination=!1,g.enablePaginationControls=!1,g.showGridFooter=!1);var n=function(a){var b=a?30*a+120:177;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px")},o=function(){return h[l].enablePaginationControls||(delete m.offset,delete m.limit),f.spin("spinner-grid"),d.get(i?_.merge(m,i):m).$promise.then(function(a){h[l].totalItems=a.count,h[l].data=a.rows,n(a.rows.length)})["catch"](function(a){console.error(a)})["finally"](function(){f.stop("spinner-grid")})};return h.deleteItem=a.confirm["delete"](function(a){var e=i?angular.copy(i):{};return _.merge(e,{id:a}),d.remove(e).$promise.then(function(){o(),b.show(c.instant("MESSAGE_WELL_DONE")+"!","success"),h.gridApi.selection.clearSelectedRows(),h.id=[]})["catch"](function(a){b.show(a.message?a.message:a.data.message,"danger")})}),h.deleteItems=a.confirm["delete"](function(){var a=i?angular.copy(i):{};return _.merge(a,{ids:h.id}),d["delete"](a).$promise.then(function(){o(),b.show(c.instant("MESSAGE_WELL_DONE")+"!","success"),h.gridApi.selection.clearSelectedRows(),h.id=[]})["catch"](function(a){b.show(a.message?a.message:a.data.message,"danger")})}),g.columnDefs.forEach(function(a){a.hasOwnProperty("displayName")||(a.displayName="APPLICATION_"+a.name.toUpperCase()),a.headerCellFilter="translate",a.hasOwnProperty("buttons")&&(a.displayName="",a.cellClass="ui-grid-vcenter",a.enableSorting=!1,a.enableFiltering=!1,a.enableColumnMenu=!1,a.cellTemplate="
",a.buttons.forEach(function(b){b.directive?a.cellTemplate+=b.directive:(a.cellTemplate+="':"",a.cellTemplate+=b.displayName||b.name?"{{'"+(b.displayName||"APPLICATION_"+b.name.toUpperCase())+"' | translate}}":"",a.cellTemplate+=" ")}),a.cellTemplate+="
",delete a.buttons)}),_.merge({enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableRowSelection:!0,enableSelectAll:!0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,getPage:o,gridMenuTitleFilter:function(a){var b=e.defer();return b.resolve(c.instant(a)),b.promise},onRegisterApi:function(a){h.gridApi=a,h.gridApi.selection.on.rowSelectionChanged(h,function(a){a.isSelected?h.id.push(h.gridApi.grid.options.primaryKey?a.entity[h.gridApi.grid.options.primaryKey]:a.entity.id):_.pull(h.id,h.gridApi.grid.options.primaryKey?a.entity[h.gridApi.grid.options.primaryKey]:a.entity.id)}),h.gridApi.selection.on.rowSelectionChangedBatch(h,function(a){a[0].isSelected?h.id=_.union(h.id,_.map(a,h.gridApi.grid.options.primaryKey?"entity."+h.gridApi.grid.options.primaryKey:"entity.id")):_.map(a,h.gridApi.grid.options.primaryKey?"entity."+h.gridApi.grid.options.primaryKey:"entity.id").forEach(function(a){_.pull(h.id,a)})}),h.gridApi.core.on.sortChanged(h,function(a,b){0===b.length?m.order=null:m.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),o()}),h.gridApi.pagination.on.paginationChanged(h,function(a,b){m.offset=(a-1)*b,m.limit=b,o()}),h.gridApi.core.on.filterChanged(h,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?m[a.name]=a.filters[0].term:delete m[a.name]}),o()}),h.gridApi.draggableRows.on.rowDropped(h,function(a){a.fromIndex!==a.toIndex&&d.update(i,h[l].data).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(a.message,"danger")})}),j||o()}},g)}}}]),angular.module("xCallyShuttleApp").controller("MainCtrl",["$scope","$rootScope","$translate","socket","Auth","xAlert","$uibModal","$log","$state","Contact",function(a,b,c,d,e,f,g,h,i,j){a.awesomeThings=[],a.isLoggedIn=e.isLoggedIn,a.isAdmin=e.isAdmin,a.getCurrentUser=e.getCurrentUser,a.workspaces=[],a.mainTab={active:!0},a.closeTab=function(b){if(a.workspaces[b].edited){var c=g.open({animation:!0,templateUrl:"app/main/closeEditedTab.modal.html",controller:"CloseEditedTabModalCtrl"});c.result.then(function(c){a.workspaces.splice(b,1)},function(){h.info("Modal dismissed at: "+new Date)})}else a.workspaces.splice(b,1)},a.createContact=function(b,d){return d.tags=d.tags?d.tags.join(","):void 0,j.save(d).$promise.then(function(d){a.workspaces.splice(b,1);var e=d.firstName;d.lastName&&(e+=" "+d.lastName),a.openContactTab({fullname:e,id:d.id}),f.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){f.show(a.message,"danger")})};var k=function(b){var c=g.open({animation:!0,templateUrl:"app/main/chooseContact.modal.html",controller:"ChooseContactModalCtrl",resolve:{eventId:function(){return b.id}}});c.result.then(function(c){c?a.openContactTab(c):a.newContact(b)},function(){h.info("Modal dismissed at: "+new Date)})};a.updateContact=function(b,d){var e=angular.copy(d);return e.tags=e.tags?e.tags.join(","):void 0,e.CompanyId||(e.CompanyId=null),j.update({id:e.id},e).$promise.then(function(){a.workspaces[b].edited=!1,f.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){f.show(c.instant(a.message)+"!","danger")})},d.socket.on("report_integration:contactmanager",function(a){console.log("choosecontact"),k(a)}),a.openContactTab=function(b){var c=_.find(a.workspaces,{contactID:b.id});if(c)c.active=!0;else{var d=b.firstName;b.lastName&&(d+=" "+b.lastName),a.workspaces.push({name:d,type:"contact",contactID:b.id,active:!0,eventData:b.uniqueid?b:null})}},a.openJscriptyTab=function(b){a.workspaces.push({name:b.name,type:"jscripty",active:!0,data:b})},a.newContact=function(b){a.workspaces.push({name:"New Contact",type:"newContact",active:!0,data:b||null,eventData:b&&b.uniqueid?b:""})},a.$on("$viewContentLoaded",function(){Metronic.init()}),b.language=c.use(),a.changeLanguage=function(a){c.use(a).then(function(a){b.language=a,("main.jscripty.projects.view"===i.current.name||"main.square.projects.view"===i.current.name)&&i.go(i.current,{},{reload:!0})})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").directive("ngSpinnerBar",["$rootScope",function(a){return{link:function(b,c){c.addClass("hide"),a.$on("$stateChangeStart",function(){"spinner-page"===c[0].id&&c.removeClass("hide")}),a.$on("$stateChangeSuccess",function(){"spinner-page"===c[0].id&&(c.addClass("hide"),$("body").removeClass("page-on-load"),Layout.setSidebarMenuActiveLink("match"),setTimeout(function(){Metronic.scrollTop()},1e3))}),a.$on("$spinnerStart",function(){"spinner-request"===c[0].id&&c.removeClass("hide")}),a.$on("$spinnerStop",function(){"spinner-request"===c[0].id&&c.addClass("hide")}),a.$on("$stateNotFound",function(){"spinner-page"===c[0].id&&c.addClass("hide")}),a.$on("$stateChangeError",function(){"spinner-page"===c[0].id&&c.addClass("hide")})}}}]).directive("a",function(){return{restrict:"E",link:function(a,b,c){(c.ngClick||""===c.href||"#"===c.href)&&b.on("click",function(a){a.preventDefault()})}}}).directive("nxEqual",function(){return{require:"ngModel",link:function(a,b,c,d){return c.nxEqual?(a.$watch(c.nxEqual,function(a){d.$setValidity("nxEqual",a===d.$viewValue)}),void d.$parsers.push(function(b){var e=b===a.$eval(c.nxEqual);return d.$setValidity("nxEqual",e),e?b:void 0})):void console.error("nxEqual expects a model as an argument!")}}}).directive("ngEnter",function(){return function(a,b,c){b.bind("keydown keypress",function(b){13===b.which&&(a.$apply(function(){a.$eval(c.ngEnter)}),b.preventDefault())})}}).directive("dropdownMenuHover",function(){return{link:function(a,b){b.dropdownHover()}}}).directive("uiSelectRequired",function(){return{require:"ngModel",link:function(a,b,c,d){d.$validators.uiSelectRequired=function(a){return a&&a.length}}}}).directive("rpattern",function(){return{restrict:"A",require:"ngModel",link:function(a,b,c,d){function e(a,b){return null==b||""===b||!h||a.test(b)?(d.$setValidity("pattern",!0),b):void d.$setValidity("pattern",!1)}var f,g=c.rpattern,h=!0;g&&(g.match(/^\/(.*)\/$/)?(g=new RegExp(g.substr(1,g.length-2)),f=function(a){return e(g,a)}):f=function(b){var c=a.$eval(g);if(!c||!c.test)throw new Error("Expected "+g+" to be a RegExp but was "+c);return e(c,b)}),d.$formatters.push(f),d.$parsers.push(f),c.$observe("required",function(a){h=a,f(d.$viewValue)})}}}).directive("conditionBuilder",["$compile","xAlert","$timeout",function(a,b,c){return{restrict:"E",scope:{element:"=",serviceindex:"=",service:"=",form:"="},templateUrl:"app/main/template/template.conditionBuilder.html",compile:function(d,e){var f,g;return f=d.contents().remove(),function(d,e,h){function i(a){var c=_.find(d.service.services[d.serviceindex].conditions,{value:a});if(c)if(d.elementType=c.type,c.arr)d.values=c.arr;else if(c.resource)return c.resource.get().$promise.then(function(a){d.values=_.map(a.rows,function(a){return{name:a[c.resValue],value:a[c.resValue]}})})["catch"](function(a){b.show($translate.instant(a.message),"danger")})}function j(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")}d._=_,d.randomName=j(),c(function(){d.element.field&&i(d.element.field)}),d.checkCondition=function(a){d.element.value="",d.element.operator="",i(a)},g||(g=a(f)),e.append(g(d,function(a){return a}))}}}}]).directive("newContact",["$compile","xAlert","socket","$translate","$timeout","Service","Tag","Company",function(a,b,c,d,e,f,g,h){return{restrict:"E",scope:{workspace:"=",index:"=",submit:"&onSubmit"},templateUrl:"app/main/template/template.contactTab.html",compile:function(a,i){return function(a,i,j){function k(){a.$watch("contact",function(b,c){angular.equals(b,c)||(a.workspace.edited=!0)},!0)}a.forms={general:{}},a.firstLoad=!0,a.detail={tab:"main"},a.contact={},a.submitButtonLabel=d.instant("APPLICATION_CONFIRM"),a.init=function(){a.workspace.data&&(a.contact.firstName=a.workspace.data.calleridname?a.workspace.data.calleridname:a.workspace.data.messageId?a.workspace.data.messageId:a.workspace.data.uniqueid?a.workspace.data.uniqueid:"",a.workspace.data.calleridnum&&(a.contact.phone=a.workspace.data.calleridnum),a.workspace.data.from&&(a.contact.email=a.workspace.data.from)),a.getTags(),a.getCompanies(),a.getServices()},a.getServices=function(){return f.get().$promise.then(function(b){a.services=b.rows,c.syncUpdates("service",a.services),a.contact.ServiceId=1,a.getCustomFields()})["catch"](function(a){b.show(d.instant(a.message)+"!","danger")})},a.getCustomFields=function(){return f.get({serviceId:a.contact.ServiceId,controller:"customfields"}).$promise.then(function(b){a.customFields=b.rows,a.customFields.forEach(function(a){a.values=JSON.parse(a.values)}),c.socket.on("custom_field:remove",function(b){_.remove(a.customFields,function(a){return b.id==a.id})}),c.socket.on("custom_field:save",function(b){if(b.ServiceId===a.contact.ServiceId){var c=_.find(a.customFields,{id:b.id});c||("string"==typeof b.values&&(b.values=JSON.parse(b.values)),a.customFields.push(b))}}),!a.firstLoad||a.workspace.data?(a.workspace.edited=!0,a.firstLoad=!1):(a.firstLoad=!1,k())})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getTags=function(){return g.get().$promise.then(function(b){a.tags=_.map(b.rows,"name")})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getCompanies=function(){return h.get().$promise.then(function(b){a.companies=b.rows,c.syncUpdates("company",a.companies)})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},e(function(){a.init()})}}}}]).directive("contact",["$compile","xAlert","socket","$timeout","Service","Tag","Company","Contact","$translate","gridOptions",function(a,b,c,d,e,f,g,h,i,j){return{restrict:"E",scope:{workspace:"=",index:"=",submit:"&onSubmit"},templateUrl:"app/main/template/template.contactTab.html",compile:function(a,k){return function(a,k,l){function m(b){var c={exporterCsvFilename:b+".csv",columnDefs:[{name:a.columns[a.log[b].show][a.log[b].detail].indexes[0],displayName:a.columns[a.log[b].show][a.log[b].detail].header[0],headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:a.columns[a.log[b].show][a.log[b].detail].indexes[1],displayName:a.columns[a.log[b].show][a.log[b].detail].header[1],headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:a.columns[a.log[b].show][a.log[b].detail].indexes[2],displayName:a.columns[a.log[b].show][a.log[b].detail].header[2],headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1}]};a["gridOptions"+b]=j.gridOptions(h,c,a,_.merge({id:a.workspace.contactID,controller:"log",logType:b},a.log[b]),!0,b),a["gridOptions"+b].getPage()}a.moment=moment,a.submitButtonLabel=i.instant("APPLICATION_UPDATE"),a.forms={general:{}},a.detail={tab:"main"},a.log={journal:{show:"phone",type:"inbound",detail:"general"},history:{show:"phone",type:"inbound",detail:"general"}},a.columns={phone:{general:{header:["APPLICATION_SOURCE","APPLICATION_DESTINATION","APPLICATION_DATE"], +indexes:["source","destination","createdAt"]},queue:{header:["APPLICATION_CALLERID","APPLICATION_QUEUE","APPLICATION_DATE"],indexes:["calleridnum","queue","createdAt"]},agent:{header:["APPLICATION_AGENT","APPLICATION_QUEUE","APPLICATION_DATE"],indexes:["membername","queue","agentcalledAt"]}},email:{general:{header:["APPLICATION_FROM","APPLICATION_TO","APPLICATION_DATE"],indexes:["from","to","createdAt"]}}},a.updateLog=function(b,c,d,e){c&&(a.log[b].show=c),d&&(a.log[b].detail=d),e&&(a.log[b].type=e),m(b)},a.getContact=function(){return h.get({id:a.workspace.contactID}).$promise.then(function(b){b.tags=b.tags?b.tags.split(","):[],a.contact=b,a.getCustomFields(b.ServiceId),a.updateLog("journal"),a.updateLog("history")})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getTags=function(){return f.get().$promise.then(function(b){a.tags=_.map(b.rows,"name")})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getCompanies=function(){return g.get().$promise.then(function(b){a.companies=b.rows,c.syncUpdates("company",a.companies)})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getCustomFields=function(d){return e.get({serviceId:d,controller:"customfields"}).$promise.then(function(b){a.customFields=b.rows,a.customFields.forEach(function(a){a.values=JSON.parse(a.values)}),c.socket.on("custom_field:remove",function(b){_.remove(a.customFields,function(a){return b.id==a.id})}),c.socket.on("custom_field:save",function(b){if(b.ServiceId===d){var c=_.find(a.customFields,{id:b.id});c||("string"==typeof b.values&&(b.values=JSON.parse(b.values)),a.customFields.push(b))}})})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},d(function(){a.getTags(),a.getCompanies(),a.getContact()})}}}}]).directive("jscripty",["$compile","xAlert","$http","socket",function(a,b,c,d){return{restrict:"E",scope:{workspace:"=",index:"=",submit:"&onSubmit"},templateUrl:"app/main/template/template.jscriptyTab.html",compile:function(a,d){return function(a,d,e){a.count=0,a.questions=[];var f=0,g=a.workspace.data.id;c.get("/api/jscripty/projects/"+g+"/download").success(function(b){if(b){c.post("/api/jscripty/projects/"+g+"/sessions",{projectId:g,status:"started"}).success(function(a){f=a.session_id,console.log(a)});var d=mxUtils.parseXml(b),e=new mxCodec(d);a.decObj=e.decode(d.documentElement);a.questions[a.count]=a.currentQuestion=_.find(a.decObj.cells,function(a){return a.vertex&&"start"==a.value.nodeName})}else console.log("No project published!"),alert("No project published!"),a.submit({index:a.index})}),a.next=function(b,c){a.currentQuestion.answer&&a.currentQuestion.answer!=c&&(a.questions=_.take(a.questions,a.count+1)),a.currentQuestion.answer=c,a.questions[a.count]=a.currentQuestion;var d=[];_.forEach(b.edges,function(a,c){if(a.source.id==b.id&&a.value){var e=a.value.split(",");e.length>1&&(_.forEach(e,function(c,d){var e=Object.create(a);e.setValue(c),b.edges.push(e)}),d.push(a))}}),_.forEach(d,function(a){_.remove(b.edges,function(b){return b.value==a.value&&b.id==a.id})}),a.currentQuestion=b,a.count++,a.questions[a.count]=b,a.saveQuestions()},a.end=function(){var d="completed";if("end"!=a.questions[a.questions.length-1].value.nodeName){var d="incomplete";a.saveQuestions()}c.put("/api/jscripty/projects/"+g+"/sessions/"+f,{status:d,completedAt:Date(),last_question_id:a.currentQuestion.id}).success(function(c){b.show("Project Ended","success"),a.submit({index:a.index})})},a.back=function(){a.count--,a.currentQuestion=a.questions[a.count]},a.setCurrentQuestion=function(b){a.count=b,a.currentQuestion=a.questions[a.count]},a.saveQuestions=function(){var b=[],d=[];_.forEach(a.questions,function(a,c){a.children&&_.forEach(a.children,function(a,b){d[b]={input_id:a.id,input_type:a.getAttribute("type",""),input_label:a.getAttribute("label",""),input_value:"checkbox"!=a.getAttribute("type","")||a.answer?a.answer:"Not selected"}}),b[c]={sessionId:f,projectId:g,question_id:a.id,question_type:a.value.nodeName,question_label:a.getAttribute("label",""),question_text:a.getAttribute("question",""),question_other_label:a.getAttribute("other"),question_other_answer:a.otheranswer,question_answer:a.answer,ReportJscriptyInputs:d},d=[]}),c.post("/api/jscripty/projects/"+g+"/sessions/"+f+"/questions/",b).success(function(a){})}}}}}]).directive("reportBuilder",["$compile",function(a){return{restrict:"E",scope:{group:"=",fields:"=",forms:"=",firstCall:"="},templateUrl:"app/main/template/template.reportBuilderView.html",compile:function(b,c){var d,e;return d=b.contents().remove(),function(b,c,f){b.operators=[{name:"AND"},{name:"OR"}],b.conditions=[{name:"="},{name:"!="},{name:"<"},{name:"<="},{name:">"},{name:">="},{name:"LIKE"}],b.addCondition=function(){b.group.rules.push({condition:"=",field:"",value:""})},b.removeCondition=function(a){b.group.rules.splice(a,1)},b.addGroup=function(){b.group.rules.push({group:{operator:"AND",rules:[{condition:"=",field:"",value:""}]}})},b.randomName=function(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")},b.removeGroup=function(){b.$parent.group&&b.$parent.group.rules.splice(b.$parent.$index,1)},e||(e=a(d)),c.append(e(b,function(a){return a}))}}}}]).directive("dynamicName",["$compile",function(a){return{restrict:"A",terminal:!0,priority:1e3,link:function(b,c,d){c.attr("name",b.$eval(d.dynamicName)),c.removeAttr("dynamic-name"),a(c)(b)}}}]).directive("onReadFile",["$parse",function(a){return{restrict:"A",scope:!1,link:function(b,c,d){var e=a(d.onReadFile);c.on("change",function(a){var c=new FileReader;c.onload=function(a){b.$apply(function(){e(b,{$fileContent:a.target.result})})},c.readAsText((a.srcElement||a.target).files[0])})}}}]).directive("motionFileDownload",["xAlert","$translate","$timeout","$location","FileSaver","$compile",function(a,b,c,d,e,f){return{restrict:"E",template:'',scope:{mimetype:"=",filename:"=",resource:"=",params:"=",btnclass:"@",btncontent:"@",tooltiptext:"@"},link:function(c,d,f){var g=d.children()[0];c.$on("download-start",function(){$(g).attr("disabled","disabled")}),c.$on("downloaded",function(a,b){var d=base64ToBlob(b,c.mimetype);e.saveAs(d,c.filename),$(g).attr("disabled",!1)}),c.download=function(){return c.$emit("download-start"),c.resource.get(c.params).$promise.then(function(a){c.$emit("downloaded",a.downloadString)})["catch"](function(d){a.show(b.instant(d.translatedMessage||d.data.translatedMessage||d.message||d.data.message),"danger"),c.download=function(){}})}}}}]).directive("audioFileDownload",["xAlert","$translate","$sce",function(a,b,c){return{restrict:"E",template:'',scope:{resource:"=",params:"="},link:function(d,e,f){var g=e.children()[0];d.$on("download-start",function(a,b){$(g).attr("disabled","disabled").html(' Loading...')}),d.$on("downloaded",function(a,b){var d=new Audio(c.trustAsResourceUrl("data:audio/ogg;base64,"+b));d.controls=!0,$(g).remove(),e.append(d),d.play()}),d.$on("error",function(a,b){$(g).removeClass("blue-stripe").addClass("red-stripe").html(' Error!')}),d.download=function(){return d.$emit("download-start"),d.resource.get(d.params).$promise.then(function(a){d.$emit("downloaded",a.downloadString)})["catch"](function(c){a.show(b.instant(c.translatedMessage||c.data.translatedMessage||c.message||c.data.message),"danger")})}}}}]).directive("uiRequired",function(){return{require:"ngModel",link:function(a,b,c,d){d.$validators.required=function(a,b){return!(b&&0===b.length&&"true"===c.uiRequired)},c.$observe("uiRequired",function(){d.$setValidity("required",!("true"===c.uiRequired&&d.$viewValue&&0===d.$viewValue.length))})}}}),angular.module("xCallyShuttleApp").filter("propsFilter",function(){return function(a,b){var c=[];return angular.isArray(a)?a.forEach(function(a){for(var d=!1,e=Object.keys(b),f=0;f=0}),b}}).filter("freshdesk",function(){var a=["requester","subject","agent","description"];return function(b){return _.remove(b,function(b){return a.indexOf(b.ticket_field.name)>=0}),b}}).filter("zendesk",function(){var a=["subject","assignee","description"];return function(b){return _.remove(b,function(b){return a.indexOf(b.type)>=0}),b}}),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main",{"abstract":!0,templateUrl:"app/main/main.html",controller:"MainCtrl",resolve:{authorization:["$q","Auth","$state","$timeout","$location",function(a,b,c,d,e){return b.getToken()?a.when():(d(function(){e.path("/login")}),a.reject())}],deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css","assets/plugins/mxgraph/js/mxClient.js"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("xAlert",["$translate","Notification",function(a,b){return{show:function(c,d){switch(d){case"success":b.success({message:c,title:' '+a.instant("MESSAGE_SUCCESS")+"!",delay:5e3});break;case"info":b.info({message:c,title:' '+a.instant("MESSAGE_INFO")+"!",delay:5e3});break;case"danger":b.error({message:c,title:' '+a.instant("MESSAGE_ERROR")+"!",delay:1e4});break;case"warning":b.warning({message:c,title:' '+a.instant("MESSAGE_WARNING")+"!",delay:1e4});break;default:b.info(c)}}}}]).factory("stResource",["$q","$filter","$timeout","$rootScope","$http","$translate","xAlert",function(a,b,c,d,e,f,g){return{getPage:function(b){var c={page:Math.ceil(b.pagination.start/b.pagination.number),per_page:b.pagination.number};b.sort.predicate&&(c.sort_by=b.sort.predicate,c.sort_order=b.sort.reverse?"DESC":"ASC"),_.forIn(b.search.predicateObject,function(a,b){c[b]=a}),b.search.params&&(c.clientQuery={},_.forIn(b.search.params,function(a,b){c.clientQuery[b]=a})),d.$broadcast("$spinnerStart"),e.get(b.url,{params:c}).success(function(a){h.resolve(a),d.$broadcast("$spinnerStop")}).error(function(a){g.show(f.instant(a.message),"danger"),d.$broadcast("$spinnerStop")});var h=a.defer();return h.promise}}}]),angular.module("xCallyShuttleApp").factory("Widget",["$resource",function(a){return a("/api/widgets/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("MarketCtrl",["$scope","$http","$translate","socket","xAlert","Modal","$timeout",function(a,b,c,d,e,f,g){function h(a,b){return Math.floor(Math.random()*(b-a+1))+a}a.initView=function(){b.get("/api/integrations").success(function(b){a.integrations=b.rows,a.groupedIntegration=_.chunk(a.integrations,4),d.syncUpdates("integration",a.integrations,function(){a.groupedIntegration=_.chunk(a.integrations,4)})}).error(function(a){e.show(a.message,"danger")})},a.isProgressing=!1,a.$on("$destroy",function(){d.unsyncUpdates("integration")}),a.installIntegration=function(d){a.status="Downloading",a.percentage=h(1,50),a.isProgressing=!0,d.downloading=!0,b.put("/api/integrations/"+d.id,{active:!0}).success(function(){g(function(){a.percentage=h(51,99),a.status="Installing"},2500),g(function(){a.percentage=100,a.isProgressing=!1,a.status="Completed!",d.downloading=!1,e.show(c.instant("MESSAGE_WELL_DONE")+".","success")},5e3)}).error(function(){d.downloading=!1,a.percentage=0,a.isProgressing=!1,e.show(c.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.uninstallIntegration=function(d){a.status="Uninstalling",a.percentage=h(1,99),a.isProgressing=!0,d.downloading=!0,b.put("/api/integrations/"+d.id,{active:!1}).success(function(){g(function(){a.percentage=100,a.isProgressing=!1,a.status="Completed!",d.downloading=!1,e.show(c.instant("MESSAGE_WELL_DONE")+".","success")},5e3)}).error(function(){d.downloading=!1,a.percentage=0,a.isProgressing=!1,e.show(c.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.market",{url:"/market",templateUrl:"app/market/market.html",controller:"MarketCtrl",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("MotionbarCtrl",["$scope","$stateParams","$cookieStore","settings","Auth",function(a,b,c,d,e){e.loginWithToken(b.token,b.userId,b.name),a.getCurrentUser=e.getCurrentUser,d.layout.pageQuickSidebarOpened=!0}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("motionbar",{url:"/motionbar",template:"
","abstract":!0}).state("motionbar.chat",{url:"/chat?token&userId&name",templateUrl:"app/motionbar/motionbar.chat.html",controller:"MotionbarCtrl"})}]),angular.module("xCallyShuttleApp").controller("SalesforceListCtrl",["$scope","$http","$rootScope","xAlert","$translate","socket","Modal","stResource",function(a,b,c,d,e,f,g,h){a.conf={accountsByPage:{name:"10",value:10}},a.accountsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.accounts={checked:[]},a.check=function(b,c){c?a.accounts.checked=angular.copy(_.map(a.displayedSalesforceAccounts,"id")):a.accounts.checked=[]},a.getAccounts=function(b){return _.map(a.displayedSalesforceAccounts,function(a){var c={};return b.forEach(function(b){c[b]=a[b]}),c})},a.initList=function(b){f.unsyncUpdates("salesforce_account"),b.url="/api/salesforce/accounts",h.getPage(b).then(function(d){a.displayedSalesforceAccounts=d.rows,b.pagination.numberOfPages=d.total_pages,c.updateTableConfig(a.accountsByPage,a.displayedSalesforceAccounts.length),c.updateTableConfig(a.conf.accountsByPage,a.displayedSalesforceAccounts.length)}),f.socket.on("salesforce_account:save",function(){a.initList(b)}),f.socket.on("salesforce_account:remove",function(c){a.accounts.checked=_.without(a.accounts.checked,c.id),a.initList(b)})},a.deleteItem=g.confirm["delete"](function(a){b["delete"]("/api/salesforce/accounts/"+a).success(function(){d.show(e.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.deleteItems=g.confirm["delete"](function(){b["delete"]("/api/salesforce/accounts",{params:{id:a.accounts.checked}}).success(function(){d.show(e.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.checkAccount=function(a){b.get("/api/salesforce/accounts/"+a+"/check").then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.salesforce.list",{url:"/list",templateUrl:"app/salesforce/list/list.html",controller:"SalesforceListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.salesforce",{url:"/salesforce",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("SalesforceAccount",["$resource",function(a){return a("/api/salesforce/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("SalesforceViewCtrl",["$scope","$http","$stateParams","$translate","$location","WizardHandler","socket","xAlert","Modal","$filter",function(a,b,c,d,e,f,g,h,i,j){a.$stateParams=c,a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:500,scrollInertia:0},a.initConfiguration=function(){a.formsConfiguration={},a.configuration={}},a.goNext=function(){f.wizard().next()},a.formValidation=function(a){return a},a.$on("$destroy",function(){g.unsyncUpdates("salesforce_configuration"),g.unsyncUpdates("salesforce_field")}),a.initView=function(){b.get("/api/salesforce/accounts/"+c.id).success(function(b){a.account=b}).error(function(a){h.show(a.message,"danger")})},a.updateItem=function(){b.put("/api/salesforce/accounts/"+c.id,a.account).success(function(){h.show(d.instant("MESSAGE_WELL_DONE")+".","success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getConfigurations=function(){b.get("/api/salesforce/configurations",{params:{AccountId:c.id}}).success(function(b){a.configurations=b,g.socket.on("salesforce_configuration:remove",function(b){_.remove(a.configurations,{id:b.id})})}).error(function(a){h.show(a.message,"danger")})},a.deleteConfiguration=i.confirm["delete"](function(a){b["delete"]("api/salesforce/configurations/"+a).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.createConfiguration=function(){a.configuration.AccountId=c.id,b.post("api/salesforce/configurations",a.configuration).success(function(a){e.path("salesforce/view/"+c.id+"/configurations/settings/"+a.id)}).error(function(){h.show("Something went wrong!","danger")})},a.fieldType=["string","variable"],a.descFieldType=["string","key_value"],a.getFields=function(){b.get("/api/salesforce/accounts/"+c.id+"/fields").success(function(b){a.accountFields=_.sortByOrder(j("salesforce")(b),"name","asc")}).error(function(a){h.show(a.message,"danger")})},a.getConfiguration=function(){b.get("/api/salesforce/configurations/"+c.configurationId).success(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,g.socket.on("salesforce_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})}).error(function(a){h.show(a.message,"danger")})},a.getVariables=function(){b.get("/api/variables").success(function(b){a.variables=b.rows}).error(function(a){h.show(a.message,"danger")})},a.removeItem=function(a){b["delete"]("api/salesforce/fields/"+a.id).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.addItemSubject=function(){var d={type:"string",content:""};b.post("/api/salesforce/configurations/"+c.configurationId+"/subject",d).success(function(b){a.subjectConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.addItemDescription=function(){var d={type:"string",content:""};b.post("/api/salesforce/configurations/"+c.configurationId+"/description",d).success(function(b){a.descriptionConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.addItemField=function(){var d={content:""};b.post("/api/salesforce/configurations/"+c.configurationId+"/field",d).success(function(b){a.fieldConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.updateField=function(a){b.put("/api/salesforce/fields/"+a.id,a).success(function(){}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.changeType=function(b){"variable"===b.type?b.content="":"string"===b.type&&(b.VariableId=null),a.updateField(b)},a.changeDescType=function(b){"key_value"===b.type?(b.content="","string"===b.keyType?b.VariableId=null:"variable"===b.keyType&&(b.keyContent="")):"string"===b.type&&(b.VariableId=null,b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){b.content="",a.updateField(b)},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"name",b);if(c)switch(c.type){case"picklist":return c.picklistValues;default:return}}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.salesforce.view",{url:"/view/:id",templateUrl:"app/salesforce/view/view.html",controller:"SalesforceViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.salesforce.view.account",{url:"/account",templateUrl:"app/salesforce/view/view.account.html"}).state("main.salesforce.view.configurations",{url:"/configurations",templateUrl:"app/salesforce/view/view.configurations.html"}).state("main.salesforce.view.configurations.settings",{url:"/settings/:configurationId",templateUrl:"app/salesforce/view/view.configurationSettings.html",controller:"SalesforceViewCtrl"}).state("main.salesforce.view.configuration",{url:"/configuration",templateUrl:"app/salesforce/view/view.configuration.html"})}]),angular.module("xCallyShuttleApp").controller("SalesforceWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={}},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){console.log(a.item),b.post("api/salesforce/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/salesforce/list")}).error(function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.salesforce.wizard",{url:"/wizard",templateUrl:"app/salesforce/wizard/wizard.html",controller:"SalesforceWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("License",["$resource",function(a){return a("/api/licenses/:id/:controller",{id:"@id"},{request:{method:"POST",params:{id:"request"}}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.license",{url:"/license",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("LicenseViewCtrl",["$scope","$rootScope","$translate","License","xAlert",function(a,b,c,d,e){a.initView=function(){d.get(function(b){a.item=b.license})},a.submitRequest=function(){d.request(a.item,function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")},function(a){switch(a.status){case 304:e.show(a.statusText,"info");break;default:e.show(a.statusText,"danger")}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.license.view",{url:"/view",templateUrl:"app/setting/license/view/view.html",controller:"LicenseViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/pricing-tables.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting",{url:"/setting",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("Setting",["$resource",function(a){return a("/api/settings/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("Smtp",["$resource",function(a){return a("/api/mail/servers/out/:id/:controller",{id:"@id"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.smtp",{url:"/smtp",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("SmtpViewCtrl",["$scope","$stateParams","$translate","MailServerOut","xAlert","usSpinnerService",function(a,b,c,d,e,f){a.initView=function(){a.item={},d.get({id:"service"}).$promise.then(function(b){a.item=b})["catch"](function(a){e.show(a.message,"danger")})},a.updateItem=function(){return a.item.id?d.update({id:a.item.id},a.item).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.message,"danger")}):(a.item.service=!0,d.save(a.item).$promise.then(function(b){a.item=b,e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.message,"danger")}))},a.test=function(){return f.spin("spinner-grid"),d.test({id:a.item.id,controller:"test"}).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})["finally"](function(){f.stop("spinner-grid")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.smtp.view",{url:"/view",templateUrl:"app/setting/smtp/view/view.html",controller:"SmtpViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("UpdateListCtrl",["$scope","gridOptions","$uibModal","$location","Update",function(a,b,c,d,e){a.initCounter=function(){a.$on("timer-stopped",function(a,b){console.log("Timer Stopped - data = ",b),d.path("/dashboard/voice")})},a.initView=function(){var c={exporterCsvFilename:"updates.csv",enableFiltering:!1,enableSorting:!1,enablePaginationControls:!1,enableSelectAll:!1,columnDefs:[{name:"message"},{width:125,name:"version",cellClass:"text-center ui-grid-vcenter"},{width:125,name:"createdAt",displayName:"APPLICATION_UPDATED_AT",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'}]};a.gridOptions=b.gridOptions(e,c,a)},a.pull=function(){c.open({animation:!0,templateUrl:"app/setting/update/list/list.pull.html",controller:"UpdateListPullCtrl"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.updates.list",{url:"/list",templateUrl:"app/setting/update/list/list.html",controller:"UpdateListCtrl"}).state("main.setting.updates.landing",{url:"/landing",templateUrl:"app/setting/update/list/landing.html",controller:"UpdateListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/error.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("UpdateListPullCtrl",["$scope","$uibModalInstance","$translate","$location","Update",function(a,b,c,d,e){a.modal={dismissable:!0,title:"Confirm Checkout",html:"Are you sure you want to checkout?",buttons:[{classes:"btn btn-success",text:"Checkout",click:function(){return e.pull().$promise["finally"](function(){b.dismiss("close"),d.path("/setting/updates/landing")})}},{classes:"btn default",text:"Cancel",click:function(){b.dismiss("cancel")}}]}}]),angular.module("xCallyShuttleApp").factory("Update",["$resource",function(a){return a("/api/updates/:id/:controller",{id:"@id"},{pull:{method:"GET",params:{id:"pull"}}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.updates",{url:"/updates",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("SquareOdbcListCtrl",["$scope","$uibModal","$translate","SquareOdbc","gridOptions","xAlert",function(a,b,c,d,e,f){a.initView=function(){var b={exporterCsvFilename:"odbc.csv",columnDefs:[{name:"name"},{name:"dsn",displayName:"APPLICATION_ODBC"},{name:"description"},{name:"action",width:250,buttons:[{"class":"blue-hoki",href:"/square/odbc/view/{{row.entity.id}}/settings",name:"settings"},{"class":"green-jungle",name:"check",displayName:"APPLICATION_CHECK_CONNECTION",onClick:"grid.appScope.checkConnection(row.entity.id)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=e.gridOptions(d,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/square/odbc/list/list.create.modal.html",controller:"SquareOdbcListCreateCtrl"});c.result.then(function(){a.gridOptions.getPage()})},a.checkConnection=function(a){return d.get({id:a,controller:"check"}).$promise.then(function(){f.show(c.instant("MESSAGE_CONNECTION_VERIFIED"),"success")})["catch"](function(){f.show(c.instant("MESSAGE_CONNECTION_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").controller("SquareOdbcListCreateCtrl",["$scope","$translate","$uibModalInstance","SquareOdbc","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.item.dsn||(a.item.dsn="DRIVER=MySQL;SERVER=127.0.0.1;UID=xcall;PWD=password;DATABASE=motion"),a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.odbc.list",{url:"/list",templateUrl:"app/square/odbc/list/list.html",controller:"SquareOdbcListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.odbc",{url:"/odbc",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("SquareOdbc",["$resource",function(a){return a("/api/square/odbc/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("SquareOdbcViewCtrl",["$scope","$translate","$stateParams","SquareOdbc","xAlert",function(a,b,c,d,e){a.odbc={},a.getOdbc=function(){return d.get({id:c.id}).$promise.then(function(b){a.odbc=b})["catch"](function(a){e.show(a.data.message,"danger")})},a.updateOdbc=function(){var f=angular.copy(a.odbc);return d.update({id:c.id},f).$promise.then(function(){e.show(b.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.odbc.view",{url:"/view/:id",templateUrl:"app/square/odbc/view/view.html",controller:"SquareOdbcViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.square.odbc.view.settings",{url:"/settings",templateUrl:"app/square/odbc/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("SquareProjectListCtrl",["$scope","$uibModal","SquareProject","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"projects.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/square/projects/view/{{row.entity.id}}",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/square/project/list/list.create.modal.html",controller:"SquareProjectListCreateCtrl"});c.result.then(function(b){ +console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("SquareProjectListCreateCtrl",["$scope","$translate","$uibModalInstance","SquareProject","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.projects.list",{url:"/list",templateUrl:"app/square/project/list/list.html",controller:"SquareProjectListCtrl",authenticate:!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.projects",{url:"/projects",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("SquareProject",["$resource",function(a){return a("/api/square/projects/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("SquareProjectViewCtrl",["$scope","$stateParams","Auth","xAlert","SquareProject",function(a,b,c,d,e){a.squareProject={},a.getProject=function(){return e.get({id:b.id}).$promise.then(function(b){a.squareProject=b,angular.element(document).ready(function(){window.onerror=function(a,b,c){try{if(null!==a&&-1!==a.indexOf("Script error."));else{var e=new Image;e.src="assets/plugins/mxgraph/images/1x1.png?msg="+encodeURIComponent(a)+"&url="+encodeURIComponent(b)+"&lnum="+encodeURIComponent(c)}}catch(f){d.show(f,"danger")}},b.token=c.getToken();var a=new EditorUi(new Editor);a.openString(b.preproduction,b.name,b),a.editor.graphChangeListener=function(a,b){var c=b.properties.rtChange||!1;c||(this.modified=!0)}})})["catch"](function(a){d.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.projects.view",{url:"/view/:id",templateUrl:"app/square/project/view/view.html",controller:"SquareProjectViewCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",serie:!0,cache:!1,files:["assets/plugins/mxgraph/css/common.css","assets/plugins/mxgraph/css/explorer.css","assets/plugins/mxgraph/styles/grapheditor.css","assets/plugins/mxgraph/styles/custom.css","assets/plugins/square/js/custom.js","assets/plugins/mxgraph/js/mxClient.js","assets/plugins/square/js/Editor.js","assets/plugins/square/js/Graph.js","assets/plugins/square/js/EditorUi.js","assets/plugins/square/js/Actions.js","assets/plugins/square/js/Menus.js","assets/plugins/square/js/Sidebar.js","assets/plugins/square/js/Toolbar.js","assets/plugins/square/js/Dialogs.js"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square",{url:"/square",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("Agent",["$resource",function(a){return a("/api/agents/:id/:controller",{id:"@id"},{changePassword:{method:"PUT",params:{controller:"password"}},update:{method:"PUT"},patch:{method:"PATCH"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.agents",{url:"/agents",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AgentListCtrl",["$scope","Agent","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"agents.csv",columnDefs:[{name:"fullname"},{name:"name",displayName:"APPLICATION_USERNAME"},{name:"internal"},{name:"email"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/staff/agents/view/{{row.entity.id}}/account",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.fullname, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.agents.list",{url:"/list",templateUrl:"app/staff/agent/list/list.html",controller:"AgentListCtrl",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("AgentViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$cookieStore","Agent","FileUploader","Auth","User",function(a,b,c,d,e,f,g,h,i,j){a.Auth=i,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.updatePassword=function(){var b={newPassword:a.agent.newPwd};return i.isAdmin()?b.id=e.id:b.oldPassword=a.agent.currentPwd,j.changePassword(b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.message,"danger")})};var k=a.uploader=new h({url:"api/users/"+e.id+"/avatar",queueLimit:1,withCredentials:!0,headers:{Authorization:"Bearer "+f.get("token")}});k.filters.push({name:"imageFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|jpg|png|jpeg|".indexOf(b)}}),k.onSuccessItem=function(b,e){a.agent.userpic=e.userpic,a.agent.id===i.getCurrentUser().id&&(i.getCurrentUser().userpic=e.userpic),c.show(d.instant("MESSAGE_WELL_DONE"),"success")},k.onErrorItem=function(){c.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")},k.onCompleteAll=function(){k.clearQueue()},a.initView=function(){return g.get({id:e.id}).$promise.then(function(b){a.agent=b,a.agent.transport=a.agent.transport?a.agent.transport.split(","):[],a.agent.allow=a.agent.allow?a.agent.allow.split(";"):[],a.agent.nat=a.agent.nat?a.agent.nat.split(","):[]})["catch"](function(a){c.show(a.message,"danger")})},a.patchItem=function(){return g.patch({id:e.id},{chatCapacity:a.agent.chatCapacity,mailCapacity:a.agent.mailCapacity,faxCapacity:a.agent.faxCapacity}).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.message,"danger")})},a.updateItem=function(){var b=angular.copy(a.agent);return delete b.password,delete b.md5secret,b.transport=b.transport.join(","),b.allow=b.allow.join(";"),b.nat=b.nat.join(","),g.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.agents.view",{url:"/view/:id",templateUrl:"app/staff/agent/view/view.html",controller:"AgentViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.staff.agents.view.account",{url:"/account",templateUrl:"app/staff/agent/view/view.account.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/scripts/jquery.sparkline.min.js","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js","assets/scripts/profile.js"]})}]}}).state("main.staff.agents.view.voice",{url:"/voice",templateUrl:"app/staff/agent/view/view.voice.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}}).state("main.staff.agents.view.chat",{url:"/chat",templateUrl:"app/staff/agent/view/view.chat.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}}).state("main.staff.agents.view.mail",{url:"/mail",templateUrl:"app/staff/agent/view/view.mail.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}}).state("main.staff.agents.view.fax",{url:"/fax",templateUrl:"app/staff/agent/view/view.fax.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}}).state("main.staff.agents.view.phonebar",{url:"/phonebar",templateUrl:"app/staff/agent/view/view.phonebar.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("AgentWizardCtrl",["$scope","$rootScope","Agent","Setting","xAlert","$location","$translate","$http","WizardHandler",function(a,b,c,d,e,f,g,h,i){a.forms={info:void 0,voice:void 0},a.item={role:"agent",allow:["alaw","ulaw","gsm"],transport:["udp"],context:"from-sip"},a.next=function(){i.wizard().next()},a.exitValidation=function(a){return a},a.getFirstFreeInternal=function(){return d.get({controller:"internal"}).$promise.then(function(b){a.item.internal=b.value})["catch"](function(a){e.show(a.data.message,"danger")})},a.createItem=function(){var b=angular.copy(a.item);return b.transport&&(b.transport=b.transport.join(",")),a.item.allow&&(b.allow=b.allow.join(";")),c.save(b).$promise.then(function(){f.path("/staff/agents/list")})["catch"](function(a){e.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.agents.wizard",{url:"/wizard",templateUrl:"app/staff/agent/wizard/wizard.html",controller:"AgentWizardCtrl",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff",{url:"/staff",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TeamCreateCtrl",["$scope","$uibModalInstance","Team","xAlert",function(a,b,c,d){a.form={},a.item={},a.ok=function(){return c.save(a.item).$promise.then(function(){b.close(a.item)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("TeamListCtrl",["$scope","Team","gridOptions","$uibModal",function(a,b,c,d){a.initView=function(){var d={exporterCsvFilename:"teams.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"{{row.entity.defaultEntry ? 'blue-hoki disabled' : 'blue-hoki'}}",href:"/staff/teams/view/{{row.entity.id}}/settings",name:"profile"},{"class":"{{row.entity.defaultEntry ? 'red-sunglo disabled' : 'red-sunglo'}}",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){d.open({animation:!0,templateUrl:"app/staff/team/list/create.modal.html",controller:"TeamCreateCtrl"}).result.then(function(){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.teams.list",{url:"/list",templateUrl:"app/staff/team/list/list.html",controller:"TeamListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Team",["$resource",function(a){return a("/api/teams/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.teams",{url:"/teams",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("TeamViewCtrl",["$scope","$http","$stateParams","$translate","Team","Agent","xAlert",function(a,b,c,d,e,f,g){var h=function(){return{select:function(b){return console.log("agents",b),e.save({id:a.team.id,controller:"agents"},{agents:b})},deselect:function(b){return e["delete"]({id:a.team.id,controller:"agents",agents:b})}}};a.initView=function(){return e.get({id:c.id}).$promise.then(function(b){a.team=b})["catch"](function(a){g.show(a.message,"danger")})},a.initAgents=function(){return f.get().$promise.then(function(b){return a.agents=b.rows,e.query({id:c.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindTeam(_.map(b,"id"),_.map(a.agents,function(a){return{id:a.id,name:a.name,fullname:a.fullname,internal:a.internal}}),h)})["catch"](function(a){g.show(a.message,"danger")})},a.updateItem=function(){var b=angular.copy(a.team);return e.update({id:c.id},b).$promise.then(function(){g.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.teams.view",{url:"/view/:id",templateUrl:"app/staff/team/view/view.html",controller:"TeamViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.staff.teams.view.agents",{url:"/agents",templateUrl:"app/staff/team/view/view.agents.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]}])}]}}).state("main.staff.teams.view.settings",{url:"/settings",templateUrl:"app/staff/team/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("TelephoneListCtrl",["$scope","Telephone","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"telephones.csv",columnDefs:[{name:"fullname"},{name:"name"},{name:"accountcode"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/staff/telephones/view/{{row.entity.id}}/account",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.fullname, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.telephones.list",{url:"/list",templateUrl:"app/staff/telephone/list/list.html",controller:"TelephoneListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Telephone",["$resource",function(a){return a("/api/telephones/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.telephones",{url:"/telephones",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("TelephoneViewCtrl",["$scope","$http","$stateParams","$translate","$cookieStore","Auth","xAlert","Telephone",function(a,b,c,d,e,f,g,h){a.initView=function(){a.Auth=f,a.forms={},h.get({id:c.id}).$promise.then(function(b){delete b.password,a.item=b,a.item.transport=a.item.transport?a.item.transport.split(","):[],a.item.allow=a.item.allow?a.item.allow.split(";"):[]})["catch"](function(a){g.show(a.message,"danger")})},a.updateItem=function(){var b=angular.copy(a.item);b.transport=b.transport.join(","),b.allow=b.allow.join(";"),h.update(b).$promise.then(function(){g.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.telephones.view",{url:"/view/:id",templateUrl:"app/staff/telephone/view/view.html",controller:"TelephoneViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.staff.telephones.view.account",{url:"/account",templateUrl:"app/staff/telephone/view/view.account.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css","assets/scripts/jquery.sparkline.min.js","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js","assets/scripts/profile.js"]})}]}})}]),angular.module("xCallyShuttleApp").controller("TelephoneWizardCtrl",["$scope","$http","$location","WizardHandler","xAlert","$translate","Telephone",function(a,b,c,d,e,f,g){a.next=function(){d.wizard().next()},a.exitValidation=function(a){return a},a.initWizard=function(){return a.forms={},a.item={allow:["alaw","ulaw","gsm"],transport:["udp"],context:"from-sip"},g.get({id:"internal"}).$promise.then(function(b){a.item.internal=b.internal})["catch"](function(a){console.error(a)})},a.createItem=function(){var b=angular.copy(a.item);return b.transport&&(b.transport=b.transport.join(",")),a.item.allow&&(b.allow=b.allow.join(";")),g.save(b).$promise.then(function(){c.path("/staff/telephones/list")})["catch"](function(a){e.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.telephones.wizard",{url:"/wizard",templateUrl:"app/staff/telephone/wizard/wizard.html",controller:"TelephoneWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("UserListCtrl",["$scope","User","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"users.csv",columnDefs:[{name:"fullname"},{name:"name",displayName:"APPLICATION_USERNAME"},{name:"email"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/staff/users/view/{{row.entity.id}}/account",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.fullname, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.users.list",{url:"/list",templateUrl:"app/staff/user/list/list.html",controller:"UserListCtrl"})}]),angular.module("xCallyShuttleApp").factory("User",["$resource",function(a){return a("/api/users/:id/:controller",{id:"@id"},{changePassword:{method:"PUT",params:{controller:"password"}},update:{method:"PUT"},me:{method:"GET",params:{id:"me"}}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.users",{url:"/users",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("UserViewCtrl",["$scope","$stateParams","$cookieStore","$translate","FileUploader","User","Auth","xAlert",function(a,b,c,d,e,f,g,h){a.Auth=g,a.initView=function(){return f.get({id:b.id}).$promise.then(function(b){a.user=b,a.user.transport=a.user.transport?a.user.transport.split(","):[],a.user.allow=a.user.allow?a.user.allow.split(";"):[]})["catch"](function(a){h.show(a.message,"danger")})},a.updateItem=function(){var c=angular.copy(a.user);return delete c.password,delete c.md5secret,c.transport=c.transport.join(","),c.allow=c.allow.join(";"),f.update({id:b.id},c).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})},a.updatePassword=function(){var c={newPassword:a.user.newPwd};return g.isAdmin()?c.id=b.id:c.oldPassword=a.user.currentPwd,f.changePassword(c).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})};var i=a.uploader=new e({url:"api/users/"+b.id+"/avatar",queueLimit:1,withCredentials:!0,headers:{Authorization:"Bearer "+c.get("token")}});i.filters.push({name:"imageFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|jpg|png|jpeg|".indexOf(b)}}),i.onSuccessItem=function(b,c){a.user.userpic=c.userpic,a.user.id===g.getCurrentUser().id&&(g.getCurrentUser().userpic=c.userpic),h.show(d.instant("MESSAGE_WELL_DONE"),"success")},i.onErrorItem=function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")},i.onCompleteAll=function(){i.clearQueue()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.users.view",{url:"/view/:id",templateUrl:"app/staff/user/view/view.html",controller:"UserViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.staff.users.view.account",{url:"/account",templateUrl:"app/staff/user/view/view.account.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css","assets/scripts/jquery.sparkline.min.js","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js","assets/scripts/profile.js"]})}]}})}]),angular.module("xCallyShuttleApp").controller("UserWizardCtrl",["$scope","$location","WizardHandler","xAlert","$translate","User",function(a,b,c,d,e,f){a.forms={info:void 0,voice:void 0},a.item={role:"user",host:"dynamic",context:"from-sip"},a.next=function(){c.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){return f.save(a.item).$promise.then(function(){b.path("/staff/users/list")})["catch"](function(a){d.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.users.wizard",{url:"/wizard",templateUrl:"app/staff/user/wizard/wizard.html",controller:"UserWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("SugarcrmListCtrl",["$scope","SugarcrmAccount","gridOptions","xAlert","$translate","Modal",function(a,b,c,d,e,f){a.initView=function(){var d={exporterCsvFilename:"sugarcrm_account.csv",columnDefs:[{name:"name",displayName:"APPLICATION_NAME"},{name:"username"},{name:"remoteUri",displayName:"APPLICATION_REMOTE_ADDRESS"},{name:"action",width:250,buttons:[{"class":"blue-hoki",href:"/sugarcrm/view/{{row.entity.id}}/account",name:"profile"},{"class":"green-jungle",name:"check",displayName:"APPLICATION_CHECK_CONNECTION",onClick:"grid.appScope.checkAccount(row.entity.id)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.checkAccount=function(a){return b.get({id:a,controller:"check"}).$promise.then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(a){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.sugarcrm.list",{url:"/list",templateUrl:"app/sugarcrm/list/list.html",controller:"SugarcrmListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.sugarcrm",{url:"/sugarcrm",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("SugarcrmAccount",["$resource",function(a){return a("/api/sugarcrm/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("SugarcrmConfiguration",["$resource",function(a){return a("/api/sugarcrm/configurations/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("SugarcrmField",["$resource",function(a){return a("/api/sugarcrm/fields/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("SugarcrmViewCtrl",["$scope","$http","$stateParams","$translate","$location","$filter","WizardHandler","socket","xAlert","Modal",function(a,b,c,d,e,f,g,h,i,j){a.$stateParams=c,a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:500,scrollInertia:0},a.initConfiguration=function(){a.formsConfiguration={},a.configuration={}},a.goNext=function(){g.wizard().next()},a.formValidation=function(a){return a},a.$on("$destroy",function(){h.unsyncUpdates("sugarcrm_configuration"),h.unsyncUpdates("sugarcrm_field")}),a.initView=function(){b.get("/api/sugarcrm/accounts/"+c.id).success(function(b){a.account=b}).error(function(a){i.show(a.message,"danger")})},a.updateItem=function(){b.put("/api/sugarcrm/accounts/"+c.id,a.account).success(function(){i.show(d.instant("MESSAGE_WELL_DONE")+".","success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getConfigurations=function(){b.get("/api/sugarcrm/configurations",{params:{AccountId:c.id}}).success(function(b){a.configurations=b,h.socket.on("sugarcrm_configuration:remove",function(b){_.remove(a.configurations,{id:b.id})})}).error(function(a){i.show(a.message,"danger")})},a.deleteConfiguration=j.confirm["delete"](function(a){b["delete"]("api/sugarcrm/configurations/"+a).success(function(){i.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.createConfiguration=function(){a.configuration.AccountId=c.id,b.post("api/sugarcrm/configurations",a.configuration).success(function(a){e.path("sugarcrm/view/"+c.id+"/configurations/settings/"+a.id)}).error(function(){i.show("Something went wrong!","danger")})},a.fieldType=["string","variable"],a.descFieldType=["string","key_value"],a.getFields=function(){b.get("/api/sugarcrm/accounts/"+c.id+"/fields").success(function(b){a.accountFields=_.sortByOrder(f("sugarcrm")(_.toArray(b)),"name","asc"),_.forEach(b,function(a){a.options=_.toArray(a.options)})}).error(function(a){i.show(a.message,"danger")})},a.getConfiguration=function(){b.get("/api/sugarcrm/configurations/"+c.configurationId).success(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,h.socket.on("sugarcrm_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})}).error(function(a){i.show(a.message,"danger")})},a.getVariables=function(){b.get("/api/variables").success(function(b){a.variables=b.rows}).error(function(a){i.show(a.message,"danger")})},a.removeItem=function(a){b["delete"]("api/sugarcrm/fields/"+a.id).success(function(){i.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.addItemSubject=function(){var d={type:"string",content:""};b.post("/api/sugarcrm/configurations/"+c.configurationId+"/subject",d).success(function(b){a.subjectConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.addItemDescription=function(){var d={type:"string",content:""};b.post("/api/sugarcrm/configurations/"+c.configurationId+"/description",d).success(function(b){a.descriptionConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.addItemField=function(){var d={content:""};b.post("/api/sugarcrm/configurations/"+c.configurationId+"/field",d).success(function(b){a.fieldConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.updateField=function(a){b.put("/api/sugarcrm/fields/"+a.id,a).success(function(){}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.changeType=function(b){"variable"===b.type?b.content="":"string"===b.type&&(b.VariableId=null),a.updateField(b)},a.changeDescType=function(b){"key_value"===b.type?(b.content="","string"===b.keyType?b.VariableId=null:"variable"===b.keyType&&(b.keyContent="")):"string"===b.type&&(b.VariableId=null,b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){b.content="",a.updateField(b)},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"name",b);return c?c.options.length>0?c.options:null:void 0}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.sugarcrm.view",{url:"/view/:id",templateUrl:"app/sugarcrm/view/view.html",controller:"SugarcrmViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.sugarcrm.view.account",{url:"/account",templateUrl:"app/sugarcrm/view/view.account.html"}).state("main.sugarcrm.view.configurations",{url:"/configurations",templateUrl:"app/sugarcrm/view/view.configurations.html"}).state("main.sugarcrm.view.configurations.settings",{url:"/settings/:configurationId",templateUrl:"app/sugarcrm/view/view.configurationSettings.html",controller:"SugarcrmViewCtrl"}).state("main.sugarcrm.view.configuration",{url:"/configuration",templateUrl:"app/sugarcrm/view/view.configuration.html"})}]),angular.module("xCallyShuttleApp").controller("SugarcrmkWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={}},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){b.post("api/sugarcrm/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/sugarcrm/list")}).error(function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.sugarcrm.wizard",{url:"/wizard",templateUrl:"app/sugarcrm/wizard/wizard.html",controller:"SugarcrmkWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("CannedAnswer",["$resource",function(a){return a("/api/answers/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.answers",{url:"/answers",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AnswerListCtrl",["$scope","$uibModal","CannedAnswer","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"answers.csv",columnDefs:[{name:"key",displayName:"APPLICATION_NAME"},{name:"value"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/answers/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.key, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){b.open({animation:!0,templateUrl:"app/tools/answer/list/list.create.modal.html",controller:"AnswerListCreateCtrl"}).result.then(function(b){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("AnswerListCreateCtrl",["$scope","$translate","$uibModalInstance","CannedAnswer","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.answers.list",{url:"/list",templateUrl:"app/tools/answer/list/list.html",controller:"AnswerListCtrl"})}]),angular.module("xCallyShuttleApp").controller("AnswerViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location","CannedAnswer",function(a,b,c,d,e,f,g){a.getAnswer=function(){return g.get({id:e.id}).$promise.then(function(b){a.answer=b})["catch"](function(a){c.show(a.data.message,"danger")})},a.updateAnswer=function(){var b=angular.copy(a.answer);return g.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.answers.view",{url:"/view/:id",templateUrl:"app/tools/answer/view/view.html",controller:"AnswerViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.answers.view.settings",{ +url:"/settings",templateUrl:"app/tools/answer/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("Automation",["$resource",function(a){return a("/api/automations/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.automations",{url:"/automations",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AutomationListCtrl",["$scope","$http","$translate","xAlert","Automation","gridOptions",function(a,b,c,d,e,f){a.onText="On",a.offText="Off",a.isActive=!0,a.size="mini",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initView=function(){var b={exporterCsvFilename:"Automations.csv",columnDefs:[{name:"name"},{name:"description"},{name:"channel"},{name:"status",cellTemplate:'
',width:100,enableFiltering:!1},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/automations/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=f.gridOptions(e,b,a)},a.updateItem=function(a){return e.update({id:a.id},a).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.error(a),d.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.automations.list",{url:"/list",templateUrl:"app/tools/automation/list/list.html",controller:"AutomationListCtrl"})}]),angular.module("xCallyShuttleApp").controller("AutomationViewCtrl",["$scope","$stateParams","$http","$translate","xAlert","automations","Automation","$location",function(a,b,c,d,e,f,g,h){a.$automations=f,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.forms={general:{}},a.addCondition=function(b){a.automation[b].push({field:"",operator:"",value:""})},a.removeCondition=function(b,c){a.automation[b].splice(c,1)},a.addAction=function(){a.automation.Actions.push({action:"",data1:"",data2:"",data3:"",data4:"",data5:""})},a.resetActionData=function(a){a.data1="",a.data2="",a.data3="",a.data4="",a.data5=""},a.removeAction=function(b){a.automation.Actions.splice(b,1)},a.initView=function(){return g.get({id:b.id}).$promise.then(function(b){a.automation=b})["catch"](function(a){e.show(a.message,"danger"),h.path("/tools/automations/list")})},a.updateAutomation=function(){return g.update({id:b.id},a.automation).$promise.then(function(){e.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.error(a),e.show(a.message,"danger")})},a.exitValidation=function(b){return console.log(b&&(a.automation.All.length||a.automation.Any.length)&&a.automation.Actions.length),b&&(a.automation.All.length||a.automation.Any.length)&&a.automation.Actions.length?!0:!1}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.automations.view",{url:"/view/:id",templateUrl:"app/tools/automation/view/view.html",controller:"AutomationViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]})}]}}).state("main.tools.automations.view.settings",{url:"/settings",templateUrl:"app/tools/automation/view/view.settings.html"}).state("main.tools.automations.view.routes",{url:"/routes",templateUrl:"app/tools/automation/view/view.routes.html"}).state("main.tools.automations.view.application",{url:"/application",templateUrl:"app/tools/automation/view/view.application.html"})}]),angular.module("xCallyShuttleApp").controller("AutomationWizardCtrl",["$scope","$http","$location","xAlert","automations","WizardHandler","Automation",function(a,b,c,d,e,f,g){a.$automations=e,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.tempData={voice:{},mail:{},chat:{},fax:{}},a.item={All:[],Any:[],Actions:[]},a.forms={general:void 0,settings:void 0},a.addCondition=function(b){a.item[b].push({field:"",operator:"",value:""})},a.removeCondition=function(b,c){a.item[b].splice(c,1)},a.addAction=function(){a.item.Actions.push({action:"",data1:"",data2:"",data3:"",data4:"",data5:""})},a.resetActionData=function(a){a.data1="",a.data2="",a.data3="",a.data4="",a.data5=""},a.removeAction=function(b){a.item.Actions.splice(b,1)},a.$watch("item.channel",function(b,c){c&&(a.tempData[c].All=_.clone(a.item.All,!0),a.tempData[c].Any=_.clone(a.item.Any,!0),a.tempData[c].Actions=_.clone(a.item.Actions,!0)),a.item.All=a.tempData[b].All?a.tempData[b].All:[],a.item.Any=a.tempData[b].Any?a.tempData[b].Any:[],a.item.Actions=a.tempData[b].Actions?a.tempData[b].Actions:[]},!0),a.item.channel="voice",a.createItem=function(){return g.save(a.item).$promise.then(function(){c.path("/tools/automations/list")})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},a.next=function(){f.wizard().next()},a.previous=function(){f.wizard().previous()},a.exitValidation=function(a){return a},a.exitSettingsValidation=function(b){return b&&(a.item.All.length||a.item.Any.length)&&a.item.Actions.length?!0:!1}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.automations.wizard",{url:"/wizard",templateUrl:"app/tools/automation/wizard/wizard.html",controller:"AutomationWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("Interval",["$resource",function(a){return a("/api/intervals/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.intervals",{url:"/intervals",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("IntervalListCtrl",["$scope","$uibModal","Interval","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"intervals.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/intervals/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/tools/interval/list/list.create.modal.html",controller:"IntervalListCreateCtrl"});c.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("IntervalListCreateCtrl",["$scope","$translate","$uibModalInstance","Interval","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(b.instant(a.data.message),"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.intervals.list",{url:"/list",templateUrl:"app/tools/interval/list/list.html",controller:"IntervalListCtrl"})}]),angular.module("xCallyShuttleApp").controller("IntervalViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","socket","$location","WizardHandler","Modal","interval",function(a,b,c,d,e,f,g,h,i,j){function k(b){console.log(b);var c,d,e,f;c=b.t_from&&b.t_to&&!b.alwaysTime?moment(b.t_from).format("HH:mm")+"-"+moment(b.t_to).format("HH:mm"):"*",b.wd_from&&"always"!==b.wd_from?(d=b.wd_from,b.wd_to&&"always"!==b.wd_to&&(d+="-"+b.wd_to)):d="*",b.md_from&&"always"!==b.md_from?(e=b.md_from,b.md_to&&"always"!==b.md_to&&(e+="-"+b.md_to)):e="*",b.m_from&&"always"!==b.m_from?(f=b.m_from,b.m_to&&"always"!==b.m_to&&(f+="-"+b.m_to)):f="*",void 0!==a.selectedSubInterval?a.interval.SubIntervals[a.selectedSubInterval].interval=c+","+d+","+e+","+f:a.subinterval.interval=c+","+d+","+e+","+f}a.$translate=d,a.$interval=j.interval,a.selectedSubInterval=void 0,a.gridOptions={columnDefs:[{name:"name",displayName:"APPLICATION_NAME",headerCellFilter:"translate"},{name:"interval",displayName:"APPLICATION_INTERVAL",headerCellFilter:"translate"},{name:"action",displayName:"APPLICATION_ACTION",headerCellFilter:"translate",width:125,cellTemplate:'{{\'APPLICATION_SETTINGS\' | translate}}{{\'APPLICATION_DELETE\' | translate}}'}]},a.forms={subinterval:void 0,general:void 0},a.initSubInterval=function(b){b&&(a.selectedSubInterval=void 0),a.subinterval={},a.splittedInterval={t_from:moment(new Date),t_to:moment(new Date),wd_from:"always",wd_to:"always",md_from:"always",md_to:"always",m_from:"always",m_to:"always",alwaysTime:!0}},a.next=function(){h.wizard().next()},a.previous=function(){h.wizard().previous()},a.exitValidation=function(a){return a},a.deselectAndRedirect=function(b){a.selectedSubInterval=void 0,g.path(b)},a.getInterval=function(){b.get("/api/intervals/"+e.id).success(function(b){a.interval=b,a.gridOptions.data=b.SubIntervals}).error(function(a){console.error(a),g.path("/tools/intervals/list")})},a.openSubInterval=function(b){a.selectedSubInterval=b,g.path("/tools/intervals/view/"+e.id+"/subintervals/settings")},a.updateInterval=function(f){a.selectedSubInterval=void 0,b.put("/api/intervals/"+e.id,a.interval).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success"),f&&g.path("/tools/intervals/view/"+e.id+"/"+f)}).error(function(a){c.show(d.instant(a.message),"danger")})},a.getSubInterval=function(){void 0===a.selectedSubInterval&&g.path("/tools/intervals/list"),a.splittedInterval={t_from:moment(new Date),t_to:moment(new Date)};var b,c=a.interval.SubIntervals[a.selectedSubInterval]?a.interval.SubIntervals[a.selectedSubInterval].interval.split(","):["*","*","*","*"];c.forEach(function(c,d){switch(d){case 0:"*"!==c?(b=c.split("-"),a.splittedInterval.t_from=moment(b[0],"HH:mm"),a.splittedInterval.t_to=moment(b[1],"HH:mm"),a.splittedInterval.alwaysTime=!1):(a.splittedInterval.t_from=moment(new Date),a.splittedInterval.t_to=moment(new Date),a.splittedInterval.alwaysTime=!0);break;case 1:"*"!==c?(b=c.split("-"),a.splittedInterval.wd_from=b[0],a.splittedInterval.wd_to=b[1]?b[1]:"always"):(a.splittedInterval.wd_from="always",a.splittedInterval.wd_to="always");break;case 2:"*"!==c?(b=c.split("-"),a.splittedInterval.md_from=b[0],a.splittedInterval.md_to=b[1]?b[1]:"always"):(a.splittedInterval.md_from="always",a.splittedInterval.md_to="always");break;case 3:"*"!==c?(b=c.split("-"),a.splittedInterval.m_from=b[0],a.splittedInterval.m_to=b[1]?b[1]:"always"):(a.splittedInterval.m_from="always",a.splittedInterval.m_to="always")}})},a.$watch("splittedInterval",function(a){a&&k(a)},!0),a.addSubInterval=function(){a.interval.SubIntervals.push(a.subinterval),a.updateInterval("subintervals")},a.deleteSubInterval=i.confirm["delete"](function(b){a.interval.SubIntervals.splice(b,1),a.updateInterval()})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.intervals.view",{url:"/view/:id",templateUrl:"app/tools/interval/view/view.html",controller:"IntervalViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.intervals.view.settings",{url:"/settings",templateUrl:"app/tools/interval/view/view.settings.html"}).state("main.tools.intervals.view.subintervals",{url:"/subintervals",templateUrl:"app/tools/interval/view/view.subintervals.html"}).state("main.tools.intervals.view.subinterval",{url:"/subinterval",templateUrl:"app/tools/interval/view/view.subinterval.html"}).state("main.tools.intervals.view.subintervals.settings",{url:"/settings",templateUrl:"app/tools/interval/view/view.subintervalSettings.html"})}]),angular.module("xCallyShuttleApp").controller("PauseListCtrl",["$scope","$log","$uibModal","$translate","Pause","gridOptions",function(a,b,c,d,e,f){a.initView=function(){var b={exporterCsvFilename:"pauses.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/pauses/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=f.gridOptions(e,b,a)},a.createItem=function(){var b=c.open({animation:!0,templateUrl:"app/tools/pause/list/list.create.modal.html",controller:"PauseListCreateCtrl"});b.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("PauseListCreateCtrl",["$scope","$translate","$uibModalInstance","Pause","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.pauses.list",{url:"/list",templateUrl:"app/tools/pause/list/list.html",controller:"PauseListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Pause",["$resource",function(a){return a("/api/pauses/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.pauses",{url:"/pauses",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("PauseViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location","Pause",function(a,b,c,d,e,f,g){a.getPause=function(){return g.get({id:e.id}).$promise.then(function(b){a.pause=b})["catch"](function(a){c.show(a.data.message,"danger")})},a.updatePause=function(){var b=angular.copy(a.pause);return g.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.pauses.view",{url:"/view/:id",templateUrl:"app/tools/pause/view/view.html",controller:"PauseViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.pauses.view.settings",{url:"/settings",templateUrl:"app/tools/pause/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("SoundListCtrl",["$scope","$http","socket","Modal","$q","FileUploader","$translate","xAlert","$cookieStore","$sce","Sound",function(a,b,c,d,e,f,g,h,i,j,k){a.Sound=k,a.isCollapsed=!0,a.downloadButtonContent='',a.downloadButtonClass="btn btn-xs blue-hoki",a["delete"]=d.confirm["delete"](function(a){b["delete"]("/api/sounds/"+a).success(function(a){}).error(function(a){console.log(a)})}),a.updateAudio=function(a,c){var d=e.defer();return b.put("/api/sounds/"+a,c).success(function(a){d.resolve()}).error(function(a){console.log(a.message),d.reject(a.message)}),d.promise},a.$on("$destroy",function(){c.unsyncUpdates("sound")}),a.initList=function(){b.get("/api/sounds").success(function(b){a.sounds=b.rows,b.rows.length||(a.isCollapsed=!1),c.syncUpdates("sound",a.sounds,function(){a.sounds.length||(a.isCollapsed=!1)})}).error(function(a){})};var l=a.uploader=new f({url:"/api/sounds",withCredentials:!0,headers:{Authorization:"Bearer "+i.get("token")}});l.filters.push({name:"customFilter",fn:function(a,b){return this.queue.length<10}}),l.onWhenAddingFileFailed=function(a,b,c){console.info("onWhenAddingFileFailed",a,b,c)},l.onAfterAddingFile=function(a){console.info("onAfterAddingFile",a)},l.onAfterAddingAll=function(a){console.info("onAfterAddingAll",a)},l.onBeforeUploadItem=function(a){console.info("onBeforeUploadItem",a)},l.onProgressItem=function(a,b){console.info("onProgressItem",a,b),a.isUploading=!0},l.onProgressAll=function(a){console.info("onProgressAll",a)},l.onSuccessItem=function(a,b,c,d){console.info("onSuccessItem",a,b,c,d),a.isUploading=!1},l.onErrorItem=function(a,b,c,d){console.info("onErrorItem",a,b,c,d),a.responseMessage=b,a.isUploading=!1},l.onCancelItem=function(a,b,c,d){console.info("onCancelItem",a,b,c,d),a.isUploading=!1},l.onCompleteItem=function(a,b,c,d){console.info("onCompleteItem",a,b,c,d),a.isUploading=!1},l.onCompleteAll=function(){console.info("onCompleteAll")},console.info("uploader",l)}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.sounds.list",{url:"/list",templateUrl:"app/tools/sound/list/list.html",controller:"SoundListCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js"]})}]}})}]),angular.module("xCallyShuttleApp").factory("Sound",["$resource",function(a){return a("/api/sounds/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.sounds",{url:"/sounds",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TagListCtrl",["$scope","$uibModal","Tag","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"tag.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/tags/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/tools/tag/list/list.create.modal.html",controller:"TagListCreateCtrl"});c.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("TagListCreateCtrl",["$scope","$translate","$uibModalInstance","Tag","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.tags.list",{url:"/list",templateUrl:"app/tools/tag/list/list.html",controller:"TagListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Tag",["$resource",function(a){return a("/api/tags/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.tags",{url:"/tags",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TagViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location","Tag",function(a,b,c,d,e,f,g){a.getTag=function(){return g.get({id:e.id}).$promise.then(function(b){a.tag=b})["catch"](function(a){c.show(a.data.message,"danger")})},a.updateTag=function(){var b=angular.copy(a.tag);return g.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.tags.view",{url:"/view/:id",templateUrl:"app/tools/tag/view/view.html",controller:"TagViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.tags.view.settings",{url:"/settings",templateUrl:"app/tools/tag/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("TemplateListCtrl",["$scope","Template","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"templates.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/tools/templates/view/{{row.entity.id}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.templates.list",{url:"/list",templateUrl:"app/tools/template/list/list.html",controller:"TemplateListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Template",["$resource",function(a){return a("/api/mail/templates/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.templates",{url:"/templates",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TemplateViewCtrl",["$scope","$http","$translate","$stateParams","xAlert","Template",function(a,b,c,d,e,f){a.initItem=function(){a.form={},a.item={},a.groups=[{title:"Voice",variables:[]},{title:"Chat",variables:["username","email","text","chatWebsite"]},{title:"Mail",variables:[]},{title:"Fax",variables:[]}],a.item=f.get({id:d.id})},a.updateItem=function(){f.update(a.item).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.templates.view",{url:"/view/:id",templateUrl:"app/tools/template/view/view.html",controller:"TemplateViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.templates.view.settings",{url:"/settings",templateUrl:"app/tools/template/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("TemplateWizardCtrl",["$scope","$location","$http","WizardHandler","xAlert","Template",function(a,b,c,d,e,f){a.initWizard=function(){a.item={},a.form={},a.groups=[{title:"Voice",variables:[]},{title:"Chat",variables:["username","email","text","chatWebsite"]},{title:"Mail",variables:[]},{title:"Fax",variables:[]}]},a.next=function(){d.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){return f.save({name:a.item.name,description:a.item.description,subject:a.item.subject||null,html:a.item.html||null,text:a.item.text||null}).$promise.then(function(){b.path("/tools/templates/list")})["catch"](function(a){e.show(data.err.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.templates.wizard",{url:"/wizard",templateUrl:"app/tools/template/wizard/wizard.html",controller:"TemplateWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools",{url:"/tools",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("TriggerListCtrl",["$scope","$http","$translate","Modal","xAlert","Trigger","gridOptions",function(a,b,c,d,e,f,g){a.onText="On",a.offText="Off",a.isActive=!0,a.size="mini",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initView=function(){var b={exporterCsvFilename:"Triggers.csv",columnDefs:[{name:"name"},{name:"description"},{name:"channel"},{name:"status",cellTemplate:'
',width:100,enableFiltering:!1},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/triggers/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=g.gridOptions(f,b,a)},a.updateItem=function(a){return f.update({id:a.id},a).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.error(a),e.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.triggers.list",{url:"/list",templateUrl:"app/tools/trigger/list/list.html",controller:"TriggerListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Trigger",["$resource",function(a){return a("/api/triggers/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.triggers",{url:"/triggers",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TriggerViewCtrl",["$scope","$stateParams","$translate","xAlert","triggers","Trigger","$location",function(a,b,c,d,e,f,g){a.$triggers=e,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.forms={general:{}},a.addCondition=function(b){a.trigger[b].push({field:"",operator:"",value:""})},a.removeCondition=function(b,c){a.trigger[b].splice(c,1)},a.addAction=function(){a.trigger.Actions.push({action:"",data1:"",data2:"",data3:"",data4:"",data5:""})},a.resetActionData=function(a){a.data1="",a.data2="",a.data3="",a.data4="",a.data5=""},a.removeAction=function(b){a.trigger.Actions.splice(b,1)},a.initView=function(){return f.get({id:b.id}).$promise.then(function(b){a.trigger=b})["catch"](function(a){d.show(a.message,"danger"),g.path("/tools/triggers/list")})},a.updateTrigger=function(){return f.update({id:b.id},a.trigger).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},a.exitValidation=function(b){return console.log(b&&(a.trigger.All.length||a.trigger.Any.length)&&a.trigger.Actions.length),b&&(a.trigger.All.length||a.trigger.Any.length)&&a.trigger.Actions.length?!0:!1}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.triggers.view",{url:"/view/:id",templateUrl:"app/tools/trigger/view/view.html",controller:"TriggerViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]})}]}}).state("main.tools.triggers.view.settings",{url:"/settings",templateUrl:"app/tools/trigger/view/view.settings.html"}).state("main.tools.triggers.view.routes",{url:"/routes",templateUrl:"app/tools/trigger/view/view.routes.html"}).state("main.tools.triggers.view.application",{url:"/application",templateUrl:"app/tools/trigger/view/view.application.html"})}]),angular.module("xCallyShuttleApp").controller("TriggerWizardCtrl",["$scope","$http","$location","xAlert","triggers","WizardHandler","Trigger",function(a,b,c,d,e,f,g){a.$triggers=e,a.tempData={voice:{},mail:{},chat:{},fax:{}},a.item={All:[],Any:[],Actions:[]},a.forms={general:void 0,settings:void 0},a.addCondition=function(b){a.item[b].push({field:"",operator:"",value:""})},a.removeCondition=function(b,c){a.item[b].splice(c,1)},a.addAction=function(){a.item.Actions.push({action:"",data1:"",data2:"",data3:"",data4:"",data5:""})},a.resetActionData=function(a){a.data1="",a.data2="",a.data3="",a.data4="",a.data5=""},a.removeAction=function(b){a.item.Actions.splice(b,1)},a.$watch("item.channel",function(b,c){c&&(a.tempData[c].All=_.clone(a.item.All,!0),a.tempData[c].Any=_.clone(a.item.Any,!0),a.tempData[c].Actions=_.clone(a.item.Actions,!0)),a.item.All=a.tempData[b].All?a.tempData[b].All:[],a.item.Any=a.tempData[b].Any?a.tempData[b].Any:[],a.item.Actions=a.tempData[b].Actions?a.tempData[b].Actions:[]},!0),a.item.channel="voice",a.createItem=function(){return g.save(a.item).$promise.then(function(){c.path("/tools/triggers/list")})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},a.next=function(){f.wizard().next()},a.previous=function(){f.wizard().previous()},a.exitValidation=function(a){return a},a.exitSettingsValidation=function(b){return b&&(a.item.All.length||a.item.Any.length)&&a.item.Actions.length?!0:!1}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.triggers.wizard",{url:"/wizard",templateUrl:"app/tools/trigger/wizard/wizard.html",controller:"TriggerWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("TrunkListCtrl",["$scope","Trunk","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"Trunks.csv",columnDefs:[{name:"name"},{name:"host"},{name:"context"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/trunks/view/{{row.entity.name}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.name)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.trunks.list",{url:"/list",templateUrl:"app/tools/trunk/list/list.html",controller:"TrunkListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Trunk",["$resource",function(a){return a("/api/trunks/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.trunks",{url:"/trunks",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TrunkViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","socket","$location","Trunk","VoiceContext",function(a,b,c,d,e,f,g,h,i){a.initView=function(){return h.get({id:e.id}).$promise.then(function(b){b.nat=b.nat?b.nat.split(","):[],b.allow=b.allow?b.allow.split(";"):[],b.insecure=b.insecure?b.insecure.split(","):[],b.transport=b.transport?b.transport.split(","):[],a.trunk=b})["catch"](function(a){console.error(a),g.path("/tools/trunks/list")})},a.updateTrunk=function(){""===a.trunk.password&&delete a.trunk.password;var b=angular.copy(a.trunk); +return b.nat=b.nat.join(","),b.allow=b.allow.join(";"),b.insecure=b.insecure.join(","),b.transport=b.transport.join(","),h.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){c.show(a.data.message,"danger")})},a.getContexts=function(){return i.get().$promise.then(function(b){a.voiceContexts=b.rows})["catch"](function(a){c.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.trunks.view",{url:"/view/:id",templateUrl:"app/tools/trunk/view/view.html",controller:"TrunkViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.trunks.view.settings",{url:"/settings",templateUrl:"app/tools/trunk/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("TrunkWizardCtrl",["$scope","$http","WizardHandler","$location","xAlert","socket","$translate",function(a,b,c,d,e,f,g){a.initWizard=function(){a.forms={},a.item={context:"from-voip-provider"}},a.next=function(d){d?b.post("/api/trunks/validate/",a.item).success(function(a){console.log(a),a.length?e.show(g.instant("MESSAGE_EXIST_TRUNK"),"danger"):c.wizard().next()}).error(function(a){e.show(g.instant(a.message),"danger")}):c.wizard().next()},a.previous=function(){c.wizard().previous()},a.exitValidation=function(a){return a},a.createItem=function(){b.post("/api/trunks/",a.item).success(function(){d.path("/tools/trunks/list")}).error(function(a){e.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.trunks.wizard",{url:"/wizard",templateUrl:"app/tools/trunk/wizard/wizard.html",controller:"TrunkWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("VariableListCtrl",["$scope","$uibModal","Variable","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"variables.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/variables/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/tools/variable/list/list.create.modal.html",controller:"VariableListCreateCtrl"});c.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("VariableListCreateCtrl",["$scope","$translate","$uibModalInstance","Variable","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.variables.list",{url:"/list",templateUrl:"app/tools/variable/list/list.html",controller:"VariableListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Variable",["$resource",function(a){return a("/api/variables/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.variables",{url:"/variables",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VariableViewCtrl",["$scope","$translate","$stateParams","xAlert","Variable",function(a,b,c,d,e){a.getVariable=function(){return e.get({id:c.id}).$promise.then(function(b){a.variable=b})["catch"](function(a){d.show(a.data.message,"danger")})},a.updateVariable=function(){return e.update({id:c.id},a.variable).$promise.then(function(){d.show(b.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){d.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.variables.view",{url:"/view/:id",templateUrl:"app/tools/variable/view/view.html",controller:"VariableViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.variables.view.settings",{url:"/settings",templateUrl:"app/tools/variable/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("YourdashboardListCloneModalCtrl",["$scope","$uibModalInstance",function(a,b){a.forms={dashboard:void 0},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("YourdashboardListCreateModalCtrl",["$scope","$uibModalInstance",function(a,b){a.forms={dashboard:void 0},a.item={},a.ok=function(){a.item.model=JSON.stringify({title:a.item.name}),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("YourdashboardListCtrl",["$scope","$http","$translate","xAlert","Modal","$uibModal","$log","YourDashboard","gridOptions",function(a,b,c,d,e,f,g,h,i){a.initView=function(){var b={exporterCsvFilename:"voice_contexts.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:220,buttons:[{"class":"green",href:"/tools/yourdashboards/show/{{row.entity.id}}",name:"view"},{"class":"blue-hoki",href:"/tools/yourdashboards/view/{{row.entity.id}}/settings",name:"settings"},{"class":"{{row.entity.defaultEntry ? 'red-sunglo disabled' : 'red-sunglo'}}",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"},{"class":"purple",name:"clone",onClick:"grid.appScope.clone(row.entity.id)"}]}]};a.gridOptions=i.gridOptions(h,b,a)},a.create=function(){var b=f.open({animation:!0,templateUrl:"app/tools/yourdashboard/list/create.modal.html",controller:"YourdashboardListCreateModalCtrl"});b.result.then(function(b){return h.save(b).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),a.gridOptions.getPage()})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},function(){g.info("Modal dismissed at: "+new Date)})},a.clone=function(b){var e=f.open({animation:!0,templateUrl:"app/tools/yourdashboard/list/clone.modal.html",controller:"YourdashboardListCloneModalCtrl"});e.result.then(function(e){return h.save({id:b,controller:"clone"},e).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),a.gridOptions.getPage()})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},function(){g.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.yourdashboards.list",{url:"/list",templateUrl:"app/tools/yourdashboard/list/list.html",controller:"YourdashboardListCtrl"})}]),angular.module("xCallyShuttleApp").controller("YourdashboardShowCtrl",["$scope","localStorageService","$http","xAlert","$translate","Auth","$stateParams","$location",function(a,b,c,d,e,f,g,h){a.Auth=f,a.getDashboard=function(){c.get("/api/dashboards/"+g.id).success(function(b){var c={name:"dashboard",structure:"4-8",enableconfirmdelete:!0,maximizable:!0,collapsible:!0};b.model=JSON.parse(b.model||'{"title":"Dashboard"}'),b.editable=f.isAdmin()&&b.editable?!0:!1,a.dashboard=_.merge(c,b)}).error(function(a){h.path("/tools/yourdashboards/list")})};var i=function(b,f,h){var i=angular.copy(a.dashboard);i.name=a.dashboard.model.title,i.model=JSON.stringify(i.model),c.put("/api/dashboards/"+g.id,i).success(function(){d.show(e.instant("MESSAGE_DASHBOARD_SAVED")+"!","success")}).error(function(b){d.show(b.message,"danger"),i.model=JSON.parse(i.model),i.name="dashboard",a.dashboard=i})};a.$on("adfDashboardChanged",i),a.$on("destroy",function(){console.log("main dashboard")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.yourdashboards.show",{url:"/show/:id",templateUrl:"app/tools/yourdashboard/show/show.html",controller:"YourdashboardShowCtrl"})}]),angular.module("xCallyShuttleApp").controller("YourdashboardViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location",function(a,b,c,d,e,f){a.radioSwitch={isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.getDashboard=function(){b.get("/api/dashboards/"+e.id).success(function(b){delete b.model,a.dashboard=b}).error(function(a){f.path("/tools/yourdashboards/list")})},a.updateDashboard=function(){var f=angular.copy(a.dashboard);b.put("/api/dashboards/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(b){c.show(d.instant(b.message),"danger"),a.dashboard=f})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.yourdashboards.view",{url:"/view/:id",templateUrl:"app/tools/yourdashboard/view/view.html",controller:"YourdashboardViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.yourdashboards.view.settings",{url:"/settings",templateUrl:"app/tools/yourdashboard/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("YourDashboard",["$resource",function(a){return a("/api/dashboards/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.yourdashboards",{url:"/yourdashboards",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ZendeskListCtrl",["$scope","ZendeskAccount","gridOptions","xAlert","$translate",function(a,b,c,d,e){a.initView=function(){var d={exporterCsvFilename:"zendesk_account.csv",columnDefs:[{name:"name",displayName:"APPLICATION_NAME"},{name:"username"},{name:"remoteUri",displayName:"APPLICATION_REMOTE_ADDRESS"},{name:"action",width:250,buttons:[{"class":"blue-hoki",href:"/zendesk/view/{{row.entity.id}}/account",name:"profile"},{"class":"green-jungle",name:"check",displayName:"APPLICATION_CHECK_CONNECTION",onClick:"grid.appScope.checkAccount(row.entity.id)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.checkAccount=function(a){return b.check({id:a}).$promise.then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.list",{url:"/list",templateUrl:"app/zendesk/list/list.html",controller:"ZendeskListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.view.configurations",{url:"/configurations",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ZendeskViewConfigurationListCtrl",["$scope","$stateParams","$translate","gridOptions","ZendeskConfiguration","$uibModal","xAlert",function(a,b,c,d,e,f,g){a.initView=function(){var c={exporterCsvFilename:"zendesk_configurations.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/zendesk/view/{{row.entity.AccountId}}/configurations/view/{{row.entity.id}}",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(e,c,a,{accountId:b.id})},a.createItem=function(){var c=f.open({animation:!0,templateUrl:"app/zendesk/view/configuration/list/create.modal.html",controller:["$scope","$uibModalInstance",function(a,b){a.form={},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]});c.result.then(function(c){return e.save({accountId:b.id},c).$promise.then(function(){a.gridOptions.getPage()})["catch"](function(a){g.show(a.data.message,"danger")})})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.view.configurations.list",{url:"/list",templateUrl:"app/zendesk/view/configuration/list/list.html",controller:"ZendeskViewConfigurationListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ZendeskViewConfigurationViewCtrl",["$scope","$stateParams","$filter","$translate","socket","ZendeskConfiguration","xAlert","variable","Variable","ZendeskAccount","Tag","ZendeskField",function(a,b,c,d,e,f,g,h,i,j,k,l){a.$on("$destroy",function(){e.unsyncUpdates("zendesk_field")}),a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:300,scrollInertia:0},a.fieldType=[{type:"string",title:"String"},{type:"variable",title:"Variable"},{type:"customVariable",title:"Custom Variable"}],a.descFieldType=[{type:"string",title:"String"},{type:"keyValue",title:"Key Value"}],a.initView=function(){a.configurationName="",a.subjectConfig=[],a.descriptionConfig=[],a.fieldConfig=[],a.selectedTags={tags:[]},a.variables=h},a.getConfiguration=function(){return f.get({accountId:b.id,id:b.configurationId}).$promise.then(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,a.selectedTags={tags:_.map(b.Tags,function(a){return a.id})},e.socket.on("zendesk_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})})["catch"](function(a){g.show(a.message,"danger")})},a.getCustomVariables=function(){return i.get().$promise.then(function(b){a.customVariables=b.rows})["catch"](function(a){g.show(a.message,"danger")})},a.getFields=function(){return j.fields({id:b.id}).$promise.then(function(b){a.accountFields=c("zendesk")(b)})["catch"](function(a){g.show(a.message,"danger")})},a.getTags=function(){return k.get().$promise.then(function(b){a.tags=b.rows})["catch"](function(a){g.show(a.message,"danger")})},a.addItem=function(c){switch(c){case"subject":case"description":var d={type:"string",content:""};break;case"field":var d={content:""}}return f.save({accountId:b.id,id:b.configurationId,controller:c},d).$promise.then(function(b){switch(c){case"subject":a.subjectConfig.push(b);break;case"description":a.descriptionConfig.push(b);break;case"field":a.fieldConfig.push(b)}})["catch"](function(a){g.show(a.data.message,"danger")})},a.changeType=function(b){"variable"===b.type?(b.content="",b.variableName=""):"string"===b.type?(b.VariableId=null,b.variableName=""):"customVariable"===b.type&&(b.VariableId=null,b.content=""),a.updateField(b)},a.updateField=function(a){return l.update({accountId:b.id,configurationId:b.configurationId,id:a.id},a).$promise.then(function(){})["catch"](function(){g.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.removeItem=function(a){return l["delete"]({accountId:b.id,configurationId:b.configurationId,id:a.id}).$promise.then(function(){g.show(d.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(){g.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.changeDescType=function(b){"keyValue"===b.type?(b.content="","string"===b.keyType?(b.VariableId=null,b.variableName=""):"variable"===b.keyType?(b.keyContent="",b.VariableId=null):"customVariable"===b.keyType&&(b.keyContent="",b.variableName="")):"string"===b.type&&(b.VariableId=null,b.variableName="",b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){if(b.content="",b.variableName="",b.nameField="",b.VariableId=null,b.idField){var c=_.find(a.accountFields,"id",b.idField);c&&(c.system_field_options?(b.customField=!1,b.nameField=c.title.toLowerCase()):b.customField=!0)}a.updateField(b)},a.updateTags=function(){return f.update({accountId:b.id,id:b.configurationId,controller:"tags"},a.selectedTags.tags).$promise.then(function(){g.show(d.instant("MESSAGE_WELL_DONE")+".","success")})["catch"](function(a){g.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"id",b);return c?c.system_field_options?c.system_field_options:null:void 0}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.view.configurations.view",{url:"/view/:configurationId",templateUrl:"app/zendesk/view/configuration/view/view.html",controller:"ZendeskViewConfigurationViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ZendeskViewCtrl",["$scope","$stateParams","$translate","xAlert","Modal","ZendeskAccount",function(a,b,c,d,e,f){a.initView=function(){return f.get({id:b.id}).$promise.then(function(b){a.account=b})["catch"](function(a){d.show(a.message,"danger")})},a.updateItem=function(){return f.update({id:b.id},a.account).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE")+".","success")})["catch"](function(){d.show(c.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.view",{url:"/view/:id",templateUrl:"app/zendesk/view/view.html",controller:"ZendeskViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.zendesk.view.account",{url:"/account",templateUrl:"app/zendesk/view/view.account.html"})}]),angular.module("xCallyShuttleApp").controller("ZendeskWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler","ZendeskAccount",function(a,b,c,d,e,f,g){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={},a.item.authType="password"},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){return g.save(a.item).$promise.then(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/zendesk/list")})["catch"](function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.wizard",{url:"/wizard",templateUrl:"app/zendesk/wizard/wizard.html",controller:"ZendeskWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("ZendeskAccount",["$resource",function(a){return a("/api/zendesk/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"},fields:{params:{controller:"fields"},isArray:!0},check:{params:{controller:"check"}}})}]).factory("ZendeskConfiguration",["$resource",function(a){return a("/api/zendesk/accounts/:accountId/configurations/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]).factory("ZendeskField",["$resource",function(a){return a("/api/zendesk/accounts/:accountId/configurations/:configurationId/fields/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk",{url:"/zendesk",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").service("application",function(){var a={applications:[{name:"Queue",value:"Queue"},{name:"Playback",value:"Playback"},{name:"Dial",value:"Dial"},{name:"Cally-Square IVR",value:"AGI"},{name:"GoTo",value:"Goto"},{name:"Hangup",value:"Hangup"},{name:"Set",value:"Set"},{name:"Custom",value:"custom"},{name:"VoiceMail",value:"Voicemail"}],queueOptions:[{value:"C",name:"APPLICATION_QUEUE_OPTION_C"},{value:"c",name:"APPLICATION_QUEUE_OPTION_c"},{value:"d",name:"APPLICATION_QUEUE_OPTION_d"},{value:"F",name:"APPLICATION_QUEUE_OPTION_F"},{value:"h",name:"APPLICATION_QUEUE_OPTION_h"},{value:"H",name:"APPLICATION_QUEUE_OPTION_H"},{value:"n",name:"APPLICATION_QUEUE_OPTION_n"},{value:"i",name:"APPLICATION_QUEUE_OPTION_i"},{value:"I",name:"APPLICATION_QUEUE_OPTION_I"},{value:"r",name:"APPLICATION_QUEUE_OPTION_r"},{value:"R",name:"APPLICATION_QUEUE_OPTION_R"},{value:"t",name:"APPLICATION_QUEUE_OPTION_t"},{value:"T",name:"APPLICATION_QUEUE_OPTION_T"},{value:"w",name:"APPLICATION_QUEUE_OPTION_w"},{value:"W",name:"APPLICATION_QUEUE_OPTION_W"},{value:"k",name:"APPLICATION_QUEUE_OPTION_k"},{value:"K",name:"APPLICATION_QUEUE_OPTION_K"},{value:"x",name:"APPLICATION_QUEUE_OPTION_x"},{value:"X",name:"APPLICATION_QUEUE_OPTION_X"}],audioOptions:[{value:"skip",name:"APPLICATION_PLAYBACK_OPTION_SKIP"},{value:"noanswer",name:"APPLICATION_PLAYBACK_OPTION_NOANSWER"},{value:"j",name:"APPLICATION_PLAYBACK_OPTION_J"},{value:"say",name:"APPLICATION_PLAYBACK_OPTION_SAY"}],hangupCauses:[{value:"",name:"--"},{value:"1",name:"APPLICATION_HANGUP_CAUSE_1"},{value:"16",name:"APPLICATION_HANGUP_CAUSE_16"},{value:"17",name:"APPLICATION_HANGUP_CAUSE_17"},{value:"18",name:"APPLICATION_HANGUP_CAUSE_18"},{value:"21",name:"APPLICATION_HANGUP_CAUSE_21"},{value:"22",name:"APPLICATION_HANGUP_CAUSE_22"},{value:"27",name:"APPLICATION_HANGUP_CAUSE_27"},{value:"38",name:"APPLICATION_HANGUP_CAUSE_38"},{value:"41",name:"APPLICATION_HANGUP_CAUSE_41"}],intTypes:[{value:"always",name:"APPLICATION_ALWAYS"},{value:"custom",name:"APPLICATION_CUSTOM"},{value:"list",name:"APPLICATION_FROM_LIST"}],checkUnderscore:function(a){return 0===a.indexOf("_")?a:"_"+a}};return{application:a}}),angular.module("xCallyShuttleApp").factory("Auth",["$location","$rootScope","$http","User","$cookieStore","$q",function(a,b,c,d,e,f){var g={};return e.get("token")&&(g=d.me()),{login:function(a,h){var i=h||angular.noop,j=f.defer();return c.post("/auth/local",{name:a.name,password:a.password,remember:a.remember}).success(function(a){return e.put("role",a.role),e.put("token",a.token),e.put("userId",a.userId),g=d.me({},function(){b.$broadcast("login")}),j.resolve(a),i()}).error(function(a){return this.logout(),j.reject(a),i(a)}.bind(this)),j.promise},loginWithToken:function(a,b,c){e.put("token",a),e.put("userId",b),e.put("name",c),g=d.me()},logout:function(){c.put("/api/users/"+g.id,{online:!1}).success(function(){e.remove("role"),e.remove("token"),e.remove("userId"),g={},b.$broadcast("logout")}).error(function(a){return a})},createUser:function(a,b){var c=b||angular.noop;return d.save(a,function(b){return e.put("token",b.token),g=d.me(),c(a)},function(a){return this.logout(),c(a)}.bind(this)).$promise},changePassword:function(a,b,c){var e=c||angular.noop;return d.changePassword({id:g.id},{oldPassword:a,newPassword:b},function(a){return e(null,a)},function(a){return e(a)}).$promise},getCurrentUser:function(){return g},isLoggedIn:function(){return g.hasOwnProperty("role")},isLoggedInAsync:function(a){g.hasOwnProperty("$promise")?g.$promise.then(function(){a(!0)})["catch"](function(){a(!1)}):a(g.hasOwnProperty("role")?!0:!1)},isAdmin:function(){return"admin"===(e.get("role")||g.role)||"user"===(e.get("role")||g.role)},getRole:function(){return g.role},getToken:function(){return e.get("token")},getUserId:function(){return console.log(e.get("userId")),e.get("userId")},getName:function(){return e.get("name")}}}]),angular.module("xCallyShuttleApp").service("automations",function(){var a={voice:{conditions:[],actions:[]},mail:{conditions:[{name:"APPLICATION_STATUS",value:"status",type:"select",arr:[{name:"APPLICATION_STATUS_NEW",value:"NEW"},{name:"APPLICATION_STATUS_OPEN",value:"OPEN"},{name:"APPLICATION_STATUS_CLOSED",value:"CLOSED"}],operators:[{value:"equals",name:"APPLICATION_EQUALS_TO"},{value:"not_equals",name:"APPLICATION_NOT_EQUALS_TO"}]},{name:"APPLICATION_HOURS_SINCE_CREATED",value:"createdAt",type:"input",operators:[{value:"greater_or_equal",name:"APPLICATION_GTE_TO"},{value:"less_or_equal",name:"APPLICATION_LTE_TO"},{value:"greater",name:"APPLICATION_GREATER_THAN"},{value:"less",name:"APPLICATION_LESS_THAN"}]}],actions:[{name:"APPLICATION_STATUS",value:"status"}]},chat:{conditions:[{name:"APPLICATION_STATUS",value:"status",type:"select",arr:[{name:"APPLICATION_STATUS_NEW",value:"NEW"},{name:"APPLICATION_STATUS_OPEN",value:"OPEN"},{name:"APPLICATION_STATUS_CLOSED",value:"CLOSED"}],operators:[{value:"equals",name:"APPLICATION_EQUALS_TO"},{value:"not_equals",name:"APPLICATION_NOT_EQUALS_TO"}]},{name:"APPLICATION_HOURS_SINCE_CREATED",value:"createdAt",type:"input",operators:[{value:"greater_or_equal",name:"APPLICATION_GTE_TO"},{value:"less_or_equal",name:"APPLICATION_LTE_TO"},{value:"greater",name:"APPLICATION_GREATER_THAN"},{value:"less",name:"APPLICATION_LESS_THAN"}]}],actions:[{name:"APPLICATION_STATUS",value:"status"}]},fax:{conditions:[{name:"APPLICATION_STATUS",value:"status",type:"select",arr:[{name:"APPLICATION_STATUS_NEW",value:"NEW"},{name:"APPLICATION_STATUS_OPEN",value:"OPEN"},{name:"APPLICATION_STATUS_CLOSED",value:"CLOSED"}],operators:[{value:"equals",name:"APPLICATION_EQUALS_TO"},{value:"not_equals",name:"APPLICATION_NOT_EQUALS_TO"}]},{name:"APPLICATION_HOURS_SINCE_CREATED",value:"createdAt",type:"input",operators:[{value:"greater_or_equal",name:"APPLICATION_GTE_TO"},{value:"less_or_equal",name:"APPLICATION_LTE_TO"},{value:"greater",name:"APPLICATION_GREATER_THAN"},{value:"less",name:"APPLICATION_LESS_THAN"}]}],actions:[{name:"APPLICATION_STATUS",value:"status"}]}},b=["voice","mail","chat","fax"];return{services:a,channels:b}}),angular.module("xCallyShuttleApp").service("desk_com",function(){var a=[{id:"priority",label:"Priority",custom:!1,data:{choices:[1,2,3,4,5,6,7,8,9,10]}},{id:"status",label:"Status",custom:!1,data:{choices:["new","open","pending","resolved","closed"]}},{id:"type",label:"Type",custom:!1,data:{choices:["chat","twitter","email","qna","facebook","phone"]}}];return{fields:a}}),angular.module("xCallyShuttleApp").controller("FooterController",["$scope","$http",function(a,b){a.year=moment().year(),a.$on("$includeContentLoaded",function(){Layout.initFooter()}),a.initFooter=function(){b.get("/api/settings/info").success(function(b){a.info=b}).error(function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").controller("HeaderController",["$scope","$rootScope","$location","$state","$http","$notification","Auth","xAlert","socket","ngAudio","settings","toastr","localStorageService","MailReport","ChatReport",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o){a.toggleQuickSidebar=function(){k.layout.pageQuickSidebarOpened=!k.layout.pageQuickSidebarOpened,k.layout.pageQuickSidebarOpened||m.remove("chatRoomId")},a.toogleSidebar=function(){k.layout.pageSidebarClosed=!k.layout.pageSidebarClosed,m.set("sidebarClosed",k.layout.pageSidebarClosed)},a.initHeader=function(){var c=j.load("api/xchatty/assets?resource=notification/xc_blubb.mp3"),d={};"agent"===g.getCurrentUser().role&&(i.socket.on("report_mail:save",function(a){c.play();var d=f("MAIL CHANNEL",{icon:"assets/images/media/channels/mail64.png",body:"NEW Incoming Mail Message!",delay:1e3*a.timeslot});d.$on("click",function(){return n.get({id:a.id,controller1:"accept",controller2:a.uniqueid}).$promise.then(function(){h.show("Mail properly assigned","success"),b.$broadcast("mailMessageEvent",{message:"Mail properly assigned.."})})["catch"](function(a){h.show(a.data.message,"danger")})})}),i.socket.on("report_chat:save",function(a){c.play(),d[a.uniqueid]&&(d[a.uniqueid].close(),delete d[a.uniqueid]),d[a.uniqueid]=f("CHAT CHANNEL",{icon:"assets/images/media/channels/chat64.png",body:"NEW Incoming Chat Visitor!",delay:1e3*a.timeslot}),d[a.uniqueid].$on("click",function(){return o.get({id:a.id,controller1:"accept",controller2:a.uniqueid}).$promise.then(function(){h.show("Chat properly assigned","success"),b.$broadcast("mailMessageEvent",{message:"Chat properly assigned.."})})["catch"](function(a){h.show(a.data.message,"danger")})})}),i.socket.on("chat_message:save",function(a){c.play();var d=m.get("chatRoomId");if((!d||d!==a.ChatRoomId)&&a.UserId&&a.UserId!==g.getCurrentUser().id){var e=f(a.User.fullname,{icon:"assets/images/media/channels/chat64.png",body:a.body.length>35?a.body.substring(0,35)+"...":a.body,delay:1e4});e.$on("click",function(){b.$broadcast("chatMessageEvent",{chatRoomId:a.ChatRoomId})})}}),i.socket.on("user_has_chat_room:save",function(a){c.play(),b.$broadcast("chatGroupEvent",a)})),e({url:"/api/fax/user_has_queues",method:"GET",params:{UserId:g.getCurrentUser().id}}).success(function(b){a.faxQueues=_.map(b,"FaxQueueId"),a.faxQueues.forEach(function(a){i.socket.on("FAX:QUEUE:"+a,function(a,b){var c=f("FAX CHANNEL",{icon:"assets/images/media/channels/telephone124.png",body:"NEW Incoming Fax Message!",delay:1e3*a.timeout});c.$on("click",function(){e.put("/api/fax/rooms/"+a.roomId,{UserId:g.getCurrentUser().id}).success(function(){c.close(),b(g.getCurrentUser().id),l.success("Fax properly assigned","Success",{closeButton:!0,timeOut:5e3})}).error(function(){l.warning("Fax already assigned","Warning",{closeButton:!0,timeOut:5e3})})})})}),i.socket.on("FAX:AGENT:"+g.getCurrentUser().id,function(a,b){var c=f("FAX CHANNEL",{icon:"assets/images/media/channels/telephone124.png",body:"NEW Incoming Fax Message!",delay:1e3*a.timeout});c.$on("click",function(){e.put("/api/fax/rooms/"+a.roomId,{UserId:g.getCurrentUser().id}).success(function(){c.close(),b(g.getCurrentUser().id),l.success("Fax properly assigned","Success",{closeButton:!0,timeOut:5e3})}).error(function(){b(g.getCurrentUser().id),l.warning("Fax already assigned","Warning",{closeButton:!0,timeOut:5e3})})})})}).error(function(a){console.error(a)}),i.socket.on("user_has_fax_queue:save",function(b){b=_.map(b,function(a){return a.UserId=parseInt(a.UserId,10),a}),b=_.find(b,{UserId:g.getCurrentUser().id}),b&&-1===_.indexOf(a.faxQueues,b.FaxQueueId)&&(a.faxQueues.push(b.FaxQueueId),i.socket.on("FAX:QUEUE:"+b.FaxQueueId,function(a,b){var c=f("FAX CHANNEL",{icon:"assets/images/media/channels/telephone124.png",body:"NEW Incoming Fax Message!",delay:1e3*a.timeout});c.$on("click",function(){e.put("/api/fax/rooms/"+a.roomId,{UserId:g.getCurrentUser().id}).success(function(){c.close(),b(g.getCurrentUser().id),l.success("Fax properly assigned","Success",{closeButton:!0,timeOut:5e3})}).error(function(){b(g.getCurrentUser().id),l.warning("Fax already assigned","Warning",{closeButton:!0,timeOut:5e3})})})}))}),i.socket.on("user_has_fax_queue:remove",function(b){_.indexOf(b.where.UserId,g.getCurrentUser().id.toString())>=0&&_.indexOf(a.faxQueues,b.where.FaxQueueId)>=0&&(a.faxQueues=_.remove(a.faxQueues,b.where.FaxQueueId),i.socket.removeAllListeners("FAX:QUEUE:"+b.where.FaxQueueId))})},a.logout=function(){e.get("/auth/local/logout").success(function(){g.logout(),c.path("/login")}).error(function(a){console.error(a)})},a.isActive=function(a){return a===c.path()}}]),angular.module("xCallyShuttleApp").service("interval",function(){var a={months:[{value:"always",name:"APPLICATION_ALWAYS"},{value:"jan",name:"APPLICATION_JANUARY"},{value:"feb",name:"APPLICATION_FEBRUARY"},{value:"mar",name:"APPLICATION_MARCH"},{value:"apr",name:"APPLICATION_APRIL"},{value:"may",name:"APPLICATION_MAY"},{value:"jun",name:"APPLICATION_JUNE"},{value:"jul",name:"APPLICATION_JULY"},{value:"aug",name:"APPLICATION_AUGUST"},{value:"sep",name:"APPLICATION_SEPTEMBER"},{value:"oct",name:"APPLICATION_OCTOBER"},{value:"nov",name:"APPLICATION_NOVEMBER"},{value:"dec",name:"APPLICATION_DECEMBER"}],daysOfWeek:[{value:"always",name:"APPLICATION_ALWAYS"},{value:"mon",name:"APPLICATION_MONDAY"},{value:"tue",name:"APPLICATION_TUESDAY"},{value:"wed",name:"APPLICATION_WEDNESDAY"},{value:"thu",name:"APPLICATION_THURSDAY"},{value:"fri",name:"APPLICATION_FRIDAY"},{value:"sat",name:"APPLICATION_SATURDAY"},{value:"sun",name:"APPLICATION_SUNDAY"}],daysOfMonth:["always",1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31]};return{interval:a}}),angular.module("xCallyShuttleApp").factory("Modal",["$rootScope","$uibModal",function(a,b){function c(c,d){ +console.log("openModal",d);var e=a.$new();return c=c||{},d=d||"modal-default",angular.extend(e,c),b.open({templateUrl:"components/modal/delete.html",windowClass:d,scope:e})}return{confirm:{"delete":function(a){return a=a||angular.noop,function(){console.log(Array.prototype.slice.call(arguments));var b,d=Array.prototype.slice.call(arguments),e=d.shift();b=c({modal:{dismissable:!0,title:"Confirm Delete",html:"

Are you sure you want to delete"+(e?" "+e+"":" selected items")+"?

",buttons:[{classes:"btn red",text:"Delete",click:function(a){b.close(a)}},{classes:"btn default",text:"Cancel",click:function(a){b.dismiss(a)}}]}},"over-topbar center"),b.result.then(function(b){a.apply(b,d)})}}}}}]),angular.module("xCallyShuttleApp").controller("QuickSidebarControllerAddModal",["$scope","$uibModalInstance","Agent","items",function(a,b,c,d){a.items=d,a.agents=c.get(function(b){a.agents=b,a.items.forEach(function(b){_.remove(a.agents.rows,{id:b.id})})}),a.selected={items:[]},a.modal={title:"APPLICATION_AGENTS_SELECTION"},a.ok=function(){b.close(_.union(_.map(a.selected.items,"id"),_.map(a.items,"id")))},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").controller("QuickSidebarControllerCloseModal",["$scope","$uibModalInstance",function(a,b){a.modal={title:"APPLICATION_CONFIRM_CLOSE",text:"MESSAGE_ARE_YOU_SURE_YOU_WANT_TO_CLOSE_THE_CHAT"},a.ok=function(){b.close()},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").controller("QuickSidebarController",["$scope","$rootScope","$window","$http","$uibModal","$log","$timeout","$interval","Auth","Agent","User","ChatRoom","ChatMessage","socket","settings","localStorageService","xAlert","$translate","QuickSidebarFactory",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s){a.emojiMessage={},a.options=s.options,a.message={body:"",user:""};var t=a.currentUser=i.getCurrentUser(),u=function(b){switch(a.messagesTab=!0,o.layout.pageQuickSidebarOpened=!0,p.set("chatRoomId",b.id),p.set("messagesTab",a.messagesTab),a.chatRoom=b,b.type){case"internal":a.currentTab=0;break;case"external":a.currentTab=2,_.find(a.chatRooms,{id:b.id})||a.chatRooms.push(b)}b.Users.length>2&&(a.currentTab=3),g(function(){angular.element("page-quick-sidebar-chat-user-messages").mCustomScrollbar("scrollTo","last")},1500)},v=function(a){console.error(a)};a.$on("$includeContentLoaded",function(){p.get("chatRoomId")&&l.get({id:p.get("chatRoomId")},u,v),p.get("currentTab")&&(a.currentTab=p.get("currentTab"))}),a.agents=j.get({offset:0,limit:1e3},function(){n.syncUpdates("agent",a.agents.rows)}),a.users=k.get({offset:0,limit:1e3},function(){n.syncUpdates("user",a.users.rows)}),a.currentTab=0,a.messagesTab=!1,a.chatRooms=l.me(function(b){a.chatRooms=b},function(a){console.error(a)}),n.socket.on("report_chat:assignment",function(a){a.agentid&&l.get({id:a.chatroomid},u,v)}),n.socket.on("chat_room:save",function(b){if(a.chatRoom&&a.chatRoom.id===b.id){_.merge(a.chatRoom,b);var c=_.find(a.chatRooms,{id:b.id});c&&_.merge(c,b)}}),n.socket.on("chat_message:save",function(b){a.chatRoom&&a.chatRoom.id===b.ChatRoomId&&(a.chatRoom.ChatMessages.push(b),angular.element("page-quick-sidebar-chat-user-messages").mCustomScrollbar("scrollTo","last"))}),n.socket.on("user_has_chat_room:save",function(b){var c=_.findIndex(a.chatRooms,{id:b.id});c>=0?a.chatRooms[c]=b:a.chatRooms.push(b)}),b.$on("chatMessageEvent",function(a,b){l.get({id:b.chatRoomId},u,v)}),b.$on("chatGroupEvent",function(b,c){a.currentTab=3,a.messagesTab=!0,o.layout.pageQuickSidebarOpened=!0,a.chatRoom=c}),a.goToTab=function(b){a.currentTab=b,a.messagesTab=!1,a.chatRoom=null,p.set("currentTab",a.currentTab),p.set("messagesTab",a.messagesTab),p.remove("chatRoomId")},a.goToMessage=function(a,b){a?l.users({users:[t.id,a]},u,v):l.get({id:b},u,v)},a.sendMessage=function(){a.message.body.trim().length&&m.save({ChatRoomId:a.chatRoom.id,body:a.message.body},function(){a.message.body=""},function(a){console.error(a)})},a.goBack=function(){a.messagesTab=!1,a.chatRoom=null,p.set("messagesTab",a.messagesTab),p.remove("chatRoomId")},a.closeChatRoom=function(a,b){var c=e.open({animation:!0,size:b,templateUrl:"components/quickSidebar/modal/close.html",controller:"QuickSidebarControllerCloseModal"});c.result.then(function(){l.update({id:a,status:"CLOSED",completeReason:"agent"}).$promise.then(function(){q.show(r.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){q.show(a.data.message,"danger")})})},a.addAgent=function(b,c){var f=e.open({animation:!0,size:c,templateUrl:"components/quickSidebar/modal/add.html",controller:"QuickSidebarControllerAddModal",resolve:{items:function(){return _.map(a.chatRoom.Users?a.chatRoom.Users:[],function(a){return{id:a.id,fullname:a.fullname}})}}});f.result.then(function(a){d.put("/api/chat/rooms/"+b+"/users",{users:a}).then(function(){q.show(r.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){q.show(a.data.message,"danger")})})};var w=function(){var b=angular.element(c),d=function(){return{h:b.height(),w:b.width()}};a.$watch(d,function(b){a.style={height:b.h-46-46-46+"px"},a.style2={height:b.h-46-46-46-180+"px"}},!0),b.bind("resize",function(){a.$apply()})};w(),a.$on("$destroy",function(){n.unsyncUpdates("agent"),n.unsyncUpdates("user")})}]),angular.module("xCallyShuttleApp").directive("resizeQuickSidebar",["$window",function(a){return function(b){var c=angular.element(a);b.getWindowDimensions=function(){return{h:c.height(),w:c.width()}},b.$watch(b.getWindowDimensions,function(a){b.style={height:a.h-46-46-46+"px"}},!0),c.bind("resize",function(){b.$apply()})}}]),angular.module("xCallyShuttleApp").factory("QuickSidebarFactory",function(){return{options:{link:!0,linkTarget:"_blank",pdf:{embed:!1},image:{embed:!0},audio:{embed:!0},code:{highlight:!0,lineNumbers:!1},basicVideo:!1,video:{embed:!1,width:null,height:null,ytTheme:"dark",details:!1,ytAuthKey:"_nkO9h1A7HlVyiUICO17oA"}}}}),angular.module("xCallyShuttleApp").filter("QuickSidebarFilterUsersGreaterThan",function(){return function(a,b){var c=[];return a.forEach(function(a){var d=0;a.ChatVisitor&&d++,d+=a.Users.length,d>b&&c.push(a)}),c}}).filter("QuickSidebarFilterUsersLowerThan",function(){return function(a,b){var c=[];return a.forEach(function(a){a.Users.length1||_.keys(b.result[0]).length>1?(a.tooManyResults=!0,a.result=null):(a.tooManyResults=!1,null!==_.values(b.result[0])[0]?a.result=_.values(b.result[0])[0].toString():a.result="--"):a.result=null})},a.counterApiCall();var d=b(function(){a.counterApiCall()},1e3*parseInt(a.config.timeout));a.$on("$destroy",function(){b.cancel(d)})}]),angular.module("adf.widget.counter").run(["$templateCache",function(a){a.put("{widgetsPath}/counter/src/edit.html","
{{$select.selected.name}}
{{$select.selected.name}}
{{$select.selected.name}}
"),a.put("{widgetsPath}/counter/src/view.html",'
{{result}}
{{config.details}}
{{config.linkText}}
')}])}(window),function(a,b){angular.module("adf.widget.pie-chart",["adf.provider"]).config(["dashboardProvider",function(a){a.widget("pie-chart",{title:"Pie-Chart",description:"Display a pie-chart starting from DB values",templateUrl:"{widgetsPath}/pie-chart/src/view.html",controller:"apiWidgetPieChartViewCtrl",edit:{templateUrl:"{widgetsPath}/pie-chart/src/edit.html",controller:"apiWidgetPieChartEditCtrl"}})}]).service("apiServicePieChart",["Widget",function(a){return{get:function(b){return a.get({condition:encodeURIComponent(b.condition),table:b.report,fields:b.fields,controller:"piechart"}).$promise.then(function(a){return a})["catch"](function(a){console.log(a)})}}}]).controller("apiWidgetPieChartEditCtrl",["$scope",function(a){function b(){return a.config.fields||(a.config.fields=[{column:"",alias:""}]),a.config.fields}a.config.reportTables=[{name:"Agents",value:"report_agent"},{name:"Calls",value:"report_call"},{name:"Dials",value:"report_dial"},{name:"Queues",value:"report_queue"},{name:"Users",value:"users"},{name:"Chat Sessions",value:"report_chat_session"},{name:"Mail Sessions",value:"report_mail_session"}],a.config.timeout=a.config.timeout?a.config.timeout:1,a.config.fields=a.config.fields?a.config.fields:[{column:"",alias:""}],a.addField=function(){b().push({})},a.removeField=function(a){b().splice(a,1)}}]).controller("apiWidgetPieChartViewCtrl",["$scope","$interval","apiServicePieChart",function(a,b,c){a.config.timeout=a.config.timeout?a.config.timeout:1,a.pieChartApiCall=function(){a.config.report&&a.config.fields.length&&""!==a.config.fields[0].column&&""!==a.config.fields[0].alias&&c.get(a.config).then(function(b){if(b&&b.result&&1===b.result.length){a.labels=[],a.data=[];for(var c in b.result[0])a.labels.push(c),a.data.push(b.result[0][c])}else a.labels=[],a.data=[]})},a.pieChartApiCall();var d=b(function(){a.pieChartApiCall()},1e3*parseInt(a.config.timeout));a.$on("$destroy",function(){b.cancel(d)})}]),angular.module("adf.widget.pie-chart").run(["$templateCache",function(a){a.put("{widgetsPath}/pie-chart/src/edit.html",'
{{$select.selected.name}}
as
'),a.put("{widgetsPath}/pie-chart/src/view.html",'
')}])}(window),function(a,b){angular.module("adf.widget.table",["adf.provider"]).value("apiServiceUrlTable","/api/widgets/table").config(["dashboardProvider",function(a){a.widget("table",{title:"Table",description:"Show tabbed results from db",templateUrl:"{widgetsPath}/table/src/view.html",controller:"apiWidgetTableViewCtrl",edit:{templateUrl:"{widgetsPath}/table/src/edit.html",controller:"apiWidgetTableEditCtrl"}})}]).service("apiServiceTable",["$q","$http","apiServiceUrlTable",function(a,b,c){return{get:function(d){var e=a.defer();return b.get(c,{params:{condition:encodeURIComponent(d.condition),table:d.report,fields:d.fields}}).success(function(a){a?e.resolve(a):e.reject()}).error(function(a){console.log(a),e.reject()}),e.promise}}}]).controller("apiWidgetTableEditCtrl",["$scope",function(a){function b(){return a.config.fields||(a.config.fields=[{column:"",alias:""}]),a.config.fields}a.config.reportTables=[{name:"Agents",value:"agent"},{name:"Calls",value:"call"},{name:"Dials",value:"dial"},{name:"Members",value:"member"},{name:"Queues",value:"queue"}],a.config.timeout=a.config.timeout?a.config.timeout:1,a.config.height=a.config.height?a.config.height:350,a.config.fields=a.config.fields?a.config.fields:[{column:"",alias:""}],a.addField=function(){b().push({})},a.removeField=function(a){b().splice(a,1)}}]).controller("apiWidgetTableViewCtrl",["$scope","$interval","apiServiceTable",function(a,b,c){a.config.timeout=a.config.timeout?a.config.timeout:1,a.config.height=a.config.height?a.config.height:350,a.config.style={"max-height":a.config.height+"px",overflow:"scroll"},a.tableApiCall=function(){a.config.condition&&a.config.report&&a.config.fields.length&&""!==a.config.fields[0].column&&""!==a.config.fields[0].alias&&c.get(a.config).then(function(b){a.results=b})},a.tableApiCall();var d=b(function(){a.tableApiCall()},1e3*parseInt(a.config.timeout));a.$on("$destroy",function(){b.cancel(d)})}]),angular.module("adf.widget.table").run(["$templateCache",function(a){a.put("{widgetsPath}/table/src/edit.html",'
{{$select.selected.name}}
as
'),a.put("{widgetsPath}/table/src/view.html",'
{{field.alias}}
{{result[field.alias]}}
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
')}])}(window),function(){angular.module("pdf",[]).directive("ngPdf",["$window",function(a){return{restrict:"E",templateUrl:function(a,b){return b.templateUrl?b.templateUrl:"partials/viewer.html"},link:function(b,c,d){var e=d.pdfUrl,f=null,g=d.page?d.page:1,h=d.scale>0?d.scale:1,i=c.find("canvas"),j=i[0],k=j.getContext("2d"),l=angular.element(a);l.on("scroll",function(){b.$apply(function(){b.scroll=l[0].scrollY})}),PDFJS.disableWorker=!0,b.pageNum=g,b.renderPage=function(a){f.getPage(a).then(function(a){var e,f,g,i={};"page-fit"!==d.scale||h?e=a.getViewport(h):(e=a.getViewport(1),f=c[0].clientWidth/e.width,g=c[0].clientHeight/e.height,h=Math.min(f,g)),j.height=e.height,j.width=e.width,i={canvasContext:k,viewport:e},a.render(i).promise.then(function(){"function"==typeof b.onPageRender&&b.onPageRender()})})},b.goPrevious=function(){b.pageToDisplay<=1||(b.pageNum=parseInt(b.pageNum)-1)},b.goNext=function(){b.pageToDisplay>=f.numPages||(b.pageNum=parseInt(b.pageNum)+1)},b.zoomIn=function(){return h=parseFloat(h)+.2,b.renderPage(b.pageToDisplay),h},b.zoomOut=function(){return h=parseFloat(h)-.2,b.renderPage(b.pageToDisplay),h},b.changePage=function(){b.renderPage(b.pageToDisplay)},b.rotate=function(){"rotate0"===j.getAttribute("class")?j.setAttribute("class","rotate90"):"rotate90"===j.getAttribute("class")?j.setAttribute("class","rotate180"):"rotate180"===j.getAttribute("class")?j.setAttribute("class","rotate270"):j.setAttribute("class","rotate0")},PDFJS.getDocument(e,null,null,b.onProgress).then(function(a){"function"==typeof b.onLoad&&b.onLoad(),f=a,b.renderPage(b.pageToDisplay),b.$apply(function(){b.pageCount=a.numPages})},function(a){a&&"function"==typeof b.onError&&b.onError(a)}),b.$watch("pageNum",function(a){b.pageToDisplay=parseInt(a),null!==f&&b.renderPage(b.pageToDisplay)})}}}])}();var Metronic=function(){var a,b=!1,c=!1,d=!1,e=!1,f=[],g="assets/",h="img/",i="plugins/",j="css/",k={blue:"#89C4F4",red:"#F3565D",green:"#1bbc9b",purple:"#9b59b6",grey:"#95a5a6",yellow:"#F8CB00"},l=function(){"rtl"===$("body").css("direction")&&(b=!0),c=!!navigator.userAgent.match(/MSIE 8.0/),d=!!navigator.userAgent.match(/MSIE 9.0/),e=!!navigator.userAgent.match(/MSIE 10.0/),e&&$("html").addClass("ie10"),(e||d||c)&&$("html").addClass("ie")},m=function(){for(var a=0;a .portlet-title > .tools > a.remove",function(a){a.preventDefault();var b=$(this).closest(".portlet");$("body").hasClass("page-portlet-fullscreen")&&$("body").removeClass("page-portlet-fullscreen"),b.find(".portlet-title .fullscreen").tooltip("destroy"),b.find(".portlet-title > .tools > .reload").tooltip("destroy"),b.find(".portlet-title > .tools > .remove").tooltip("destroy"),b.find(".portlet-title > .tools > .config").tooltip("destroy"), +b.find(".portlet-title > .tools > .collapse, .portlet > .portlet-title > .tools > .expand").tooltip("destroy"),b.remove()}),$("body").on("click",".portlet > .portlet-title .fullscreen",function(a){a.preventDefault();var b=$(this).closest(".portlet");if(b.hasClass("portlet-fullscreen"))$(this).removeClass("on"),b.removeClass("portlet-fullscreen"),$("body").removeClass("page-portlet-fullscreen"),b.children(".portlet-body").css("height","auto");else{var c=Metronic.getViewPort().height-b.children(".portlet-title").outerHeight()-parseInt(b.children(".portlet-body").css("padding-top"))-parseInt(b.children(".portlet-body").css("padding-bottom"));$(this).addClass("on"),b.addClass("portlet-fullscreen"),$("body").addClass("page-portlet-fullscreen"),b.children(".portlet-body").css("height",c)}}),$("body").on("click",".portlet > .portlet-title > .tools > a.reload",function(a){a.preventDefault();var b=$(this).closest(".portlet").children(".portlet-body"),c=$(this).attr("data-url"),d=$(this).attr("data-error-display");c?(Metronic.blockUI({target:b,animate:!0,overlayColor:"none"}),$.ajax({type:"GET",cache:!1,url:c,dataType:"html",success:function(a){Metronic.unblockUI(b),b.html(a)},error:function(a,c,e){Metronic.unblockUI(b);var f="Error on reloading the content. Please check your connection and try again.";"toastr"==d&&toastr?toastr.error(f):"notific8"==d&&$.notific8?($.notific8("zindex",11500),$.notific8(f,{theme:"ruby",life:3e3})):alert(f)}})):(Metronic.blockUI({target:b,animate:!0,overlayColor:"none"}),window.setTimeout(function(){Metronic.unblockUI(b)},1e3))}),$('.portlet .portlet-title a.reload[data-load="true"]').click(),$("body").on("click",".portlet > .portlet-title > .tools > .collapse, .portlet .portlet-title > .tools > .expand",function(a){a.preventDefault()})},p=function(){if($().uniform){var a=$("input[type=checkbox]:not(.toggle, .make-switch, .icheck), input[type=radio]:not(.toggle, .star, .make-switch, .icheck)");a.size()>0&&a.each(function(){0===$(this).parents(".checker").size()&&$(this).show()})}},q=function(){$().iCheck&&$(".icheck").each(function(){var a=$(this).attr("data-checkbox")?$(this).attr("data-checkbox"):"icheckbox_minimal-grey",b=$(this).attr("data-radio")?$(this).attr("data-radio"):"iradio_minimal-grey";a.indexOf("_line")>-1||b.indexOf("_line")>-1?$(this).iCheck({checkboxClass:a,radioClass:b,insert:'
'+$(this).attr("data-label")}):$(this).iCheck({checkboxClass:a,radioClass:b})})},r=function(){$().bootstrapSwitch&&$(".make-switch").bootstrapSwitch()},s=function(){$().confirmation&&$("[data-toggle=confirmation]").confirmation({container:"body",btnOkClass:"btn-xs btn-success",btnCancelClass:"btn-xs btn-danger"})},t=function(){$("body").on("shown.bs.collapse",".accordion.scrollable",function(a){Metronic.scrollTo($(a.target))})},u=function(){if(location.hash){var a=location.hash.substr(1);$('a[href="#'+a+'"]').parents(".tab-pane:hidden").each(function(){var a=$(this).attr("id");$('a[href="#'+a+'"]').click()}),$('a[href="#'+a+'"]').click()}},v=function(){$("body").on("hide.bs.modal",function(){$(".modal:visible").size()>1&&$("html").hasClass("modal-open")===!1?$("html").addClass("modal-open"):$(".modal:visible").size()<=1&&$("html").removeClass("modal-open")}),$("body").on("show.bs.modal",".modal",function(){$(this).hasClass("modal-scroll")&&$("body").addClass("modal-open-noscroll")}),$("body").on("hide.bs.modal",".modal",function(){$("body").removeClass("modal-open-noscroll")}),$("body").on("hidden.bs.modal",".modal:not(.modal-cached)",function(){$(this).removeData("bs.modal")})},w=function(){$(".tooltips").tooltip(),$(".portlet > .portlet-title .fullscreen").tooltip({container:"body",title:"Fullscreen"}),$(".portlet > .portlet-title > .tools > .reload").tooltip({container:"body",title:"Reload"}),$(".portlet > .portlet-title > .tools > .remove").tooltip({container:"body",title:"Remove"}),$(".portlet > .portlet-title > .tools > .config").tooltip({container:"body",title:"Settings"}),$(".portlet > .portlet-title > .tools > .collapse, .portlet > .portlet-title > .tools > .expand").tooltip({container:"body",title:"Collapse/Expand"})},x=function(){$("body").on("click",".dropdown-menu.hold-on-click",function(a){a.stopPropagation()})},y=function(){$("body").on("click",'[data-close="alert"]',function(a){$(this).parent(".alert").hide(),$(this).closest(".note").hide(),a.preventDefault()}),$("body").on("click",'[data-close="note"]',function(a){$(this).closest(".note").hide(),a.preventDefault()}),$("body").on("click",'[data-remove="note"]',function(a){$(this).closest(".note").remove(),a.preventDefault()})},z=function(){$('[data-hover="dropdown"]').not(".hover-initialized").each(function(){$(this).dropdownHover(),$(this).addClass("hover-initialized")})},A=function(){$(".popovers").popover(),$(document).on("click.bs.popover.data-api",function(b){a&&a.popover("hide")})},B=function(){Metronic.initSlimScroll(".scroller")},C=function(){jQuery.fancybox&&$(".fancybox-button").size()>0&&$(".fancybox-button").fancybox({groupAttr:"data-rel",prevEffect:"none",nextEffect:"none",closeBtn:!0,helpers:{title:{type:"inside"}}})},D=function(){(c||d)&&$("input[placeholder]:not(.placeholder-no-fix), textarea[placeholder]:not(.placeholder-no-fix)").each(function(){var a=$(this);""===a.val()&&""!==a.attr("placeholder")&&a.addClass("placeholder").val(a.attr("placeholder")),a.focus(function(){a.val()==a.attr("placeholder")&&a.val("")}),a.blur(function(){(""===a.val()||a.val()==a.attr("placeholder"))&&a.val(a.attr("placeholder"))})})},E=function(){$().select2&&$(".select2me").select2({placeholder:"Select"})};return{init:function(){l(),n(),p(),q(),r(),B(),C(),E(),o(),y(),x(),u(),w(),A(),t(),v(),s(),D()},initAjax:function(){p(),q(),r(),z(),B(),E(),C(),x(),w(),A(),t(),s()},initComponents:function(){this.initAjax()},setLastPopedPopover:function(b){a=b},addResizeHandler:function(a){f.push(a)},runResizeHandlers:function(){m()},scrollTo:function(a,b){var c=a&&a.size()>0?a.offset().top:0;a&&($("body").hasClass("page-header-fixed")&&(c-=$(".page-header").height()),c+=b?b:-1*a.height()),$("html,body").animate({scrollTop:c},"slow")},initSlimScroll:function(a){$(a).each(function(){if(!$(this).attr("data-initialized")){var a;a=$(this).attr("data-height")?$(this).attr("data-height"):$(this).css("height"),$(this).slimScroll({allowPageScroll:!0,size:"7px",color:$(this).attr("data-handle-color")?$(this).attr("data-handle-color"):"#bbb",wrapperClass:$(this).attr("data-wrapper-class")?$(this).attr("data-wrapper-class"):"slimScrollDiv",railColor:$(this).attr("data-rail-color")?$(this).attr("data-rail-color"):"#eaeaea",position:b?"left":"right",height:a,alwaysVisible:"1"==$(this).attr("data-always-visible")?!0:!1,railVisible:"1"==$(this).attr("data-rail-visible")?!0:!1,disableFadeOut:!0}),$(this).attr("data-initialized","1")}})},destroySlimScroll:function(a){$(a).each(function(){if("1"===$(this).attr("data-initialized")){$(this).removeAttr("data-initialized"),$(this).removeAttr("style");var a={};$(this).attr("data-handle-color")&&(a["data-handle-color"]=$(this).attr("data-handle-color")),$(this).attr("data-wrapper-class")&&(a["data-wrapper-class"]=$(this).attr("data-wrapper-class")),$(this).attr("data-rail-color")&&(a["data-rail-color"]=$(this).attr("data-rail-color")),$(this).attr("data-always-visible")&&(a["data-always-visible"]=$(this).attr("data-always-visible")),$(this).attr("data-rail-visible")&&(a["data-rail-visible"]=$(this).attr("data-rail-visible")),$(this).slimScroll({wrapperClass:$(this).attr("data-wrapper-class")?$(this).attr("data-wrapper-class"):"slimScrollDiv",destroy:!0});var b=$(this);$.each(a,function(a,c){b.attr(a,c)})}})},scrollTop:function(){Metronic.scrollTo()},blockUI:function(a){a=$.extend(!0,{},a);var b="";if(b=a.animate?'
':a.iconOnly?'
':a.textOnly?'
  '+(a.message?a.message:"LOADING...")+"
":'
  '+(a.message?a.message:"LOADING...")+"
",a.target){var c=$(a.target);c.height()<=$(window).height()&&(a.cenrerY=!0),c.block({message:b,baseZ:a.zIndex?a.zIndex:1e3,centerY:void 0!==a.cenrerY?a.cenrerY:!1,css:{top:"10%",border:"0",padding:"0",backgroundColor:"none"},overlayCSS:{backgroundColor:a.overlayColor?a.overlayColor:"#555",opacity:a.boxed?.05:.1,cursor:"wait"}})}else $.blockUI({message:b,baseZ:a.zIndex?a.zIndex:1e3,css:{border:"0",padding:"0",backgroundColor:"none"},overlayCSS:{backgroundColor:a.overlayColor?a.overlayColor:"#555",opacity:a.boxed?.05:.1,cursor:"wait"}})},unblockUI:function(a){a?$(a).unblock({onUnblock:function(){$(a).css("position",""),$(a).css("zoom","")}}):$.unblockUI()},startPageLoading:function(a){a&&a.animate?($(".page-spinner-bar").remove(),$("body").append('
')):($(".page-loading").remove(),$("body").append('
  '+(a&&a.message?a.message:"Loading...")+"
"))},stopPageLoading:function(){$(".page-loading, .page-spinner-bar").remove()},alert:function(a){a=$.extend(!0,{container:"",place:"append",type:"success",message:"",close:!0,reset:!0,focus:!0,closeInSeconds:0,icon:""},a);var b=Metronic.getUniqueID("Metronic_alert"),c='
'+(a.close?'':"")+(""!==a.icon?' ':"")+a.message+"
";return a.reset&&$(".Metronic-alerts").remove(),a.container?"append"==a.place?$(a.container).append(c):$(a.container).prepend(c):$("body").hasClass("page-container-bg-solid")?$(".page-title").after(c):$(".page-bar").size()>0?$(".page-bar").after(c):$(".page-breadcrumb").after(c),a.focus&&Metronic.scrollTo($("#"+b)),a.closeInSeconds>0&&setTimeout(function(){$("#"+b).remove()},1e3*a.closeInSeconds),b},initUniform:function(a){a?$(a).each(function(){0===$(this).parents(".checker").size()&&($(this).show(),$(this).uniform())}):p()},updateUniform:function(a){$.uniform.update(a)},initFancybox:function(){C()},getActualVal:function(a){return a=$(a),a.val()===a.attr("placeholder")?"":a.val()},getURLParameter:function(a){var b,c,d=window.location.search.substring(1),e=d.split("&");for(b=0;b a").each(function(){var a=$(this).attr("href").toLowerCase();return a.length>1&&d.substr(1,a.length-1)==a.substr(1)?void(b=$(this)):void 0}),b&&0!=b.size()&&"javascript:;"!==b.attr("href").toLowerCase()&&"#"!==b.attr("href").toLowerCase()){parseInt(e.data("slide-speed")),e.data("keep-expanded");e.find("li.active").removeClass("active"),e.find("li > a > .selected").remove(),e.hasClass("page-sidebar-menu-hover-submenu")===!1?e.find("li.open").each(function(){0===$(this).children(".sub-menu").size()&&($(this).removeClass("open"),$(this).find("> a > .arrow.open").removeClass("open"))}):e.find("li.open").removeClass("open"),b.parents("li").each(function(){$(this).addClass("active"),$(this).find("> a > span.arrow").addClass("open"),1===$(this).parent("ul.page-sidebar-menu").size()&&$(this).find("> a").append(''),1===$(this).children("ul.sub-menu").size()&&$(this).addClass("open")}),"click"===a&&Metronic.getViewPort().width a",function(a){var b=$(this).next().hasClass("sub-menu");if(!(Metronic.getViewPort().width>=c&&1===$(this).parents(".page-sidebar-menu-hover-submenu").size())){if(b===!1)return void(Metronic.getViewPort().width a.ajaxify",function(a){a.preventDefault(),Metronic.scrollTop();var b=$(this).attr("href"),d=jQuery(".page-sidebar ul"),e=($(".page-content"),$(".page-content .page-content-body"));d.children("li.active").removeClass("active"),d.children("arrow.open").removeClass("open"),$(this).parents("li").each(function(){$(this).addClass("active"),$(this).children("a > span.arrow").addClass("open")}),$(this).parents("li").addClass("active"),Metronic.getViewPort().width li.open > a").click(),Metronic.stopPageLoading(),e.html(a),Layout.fixContentHeight(),Metronic.initAjax()},error:function(a,b,c){Metronic.stopPageLoading(),e.html("

Could not load the requested content.

")}})}),jQuery(".page-content").on("click",".ajaxify",function(a){a.preventDefault(),Metronic.scrollTop();var b=$(this).attr("href"),d=($(".page-content"),$(".page-content .page-content-body"));Metronic.startPageLoading(),Metronic.getViewPort().widthCould not load the requested content."),Metronic.stopPageLoading()}})}),i(),$(".page-sidebar").on("click",".sidebar-search .remove",function(a){a.preventDefault(),$(".sidebar-search").removeClass("open")}),$(".page-sidebar .sidebar-search").on("keypress","input.form-control",function(a){return 13==a.which?($(".sidebar-search").submit(),!1):void 0}),0!==$(".sidebar-search").size()&&($(".sidebar-search .input-group").on("click",function(a){a.stopPropagation()}),$("body").on("click",function(){$(".sidebar-search").hasClass("open")&&$(".sidebar-search").removeClass("open")}))},g=function(){var a=Metronic.getViewPort().height-$(".page-header").outerHeight();return $("body").hasClass("page-footer-fixed")&&(a-=$(".page-footer").outerHeight()),a},h=function(){var a=$(".page-sidebar-menu");return Metronic.destroySlimScroll(a),0===$(".page-sidebar-fixed").size()?void d():void(Metronic.getViewPort().width>=c&&(a.attr("data-height",g()),Metronic.initSlimScroll(a),d()))},i=function(){var a=$("body");a.hasClass("page-sidebar-fixed")&&$(".page-sidebar").on("mouseenter",function(){a.hasClass("page-sidebar-closed")&&$(this).find(".page-sidebar-menu").removeClass("page-sidebar-menu-closed")}).on("mouseleave",function(){a.hasClass("page-sidebar-closed")&&$(this).find(".page-sidebar-menu").addClass("page-sidebar-menu-closed")})},j=function(){$("body");$.cookie&&"1"===$.cookie("sidebar_closed")&&Metronic.getViewPort().width>=c?($("body").addClass("page-sidebar-closed"),$(".page-sidebar-menu").addClass("page-sidebar-menu-closed")):$.cookie&&$.cookie("sidebar_closed","0")},k=function(){$(".page-header").on("click",'.hor-menu a[data-toggle="tab"]',function(a){a.preventDefault();var b=$(".hor-menu .nav"),c=b.find("li.current");$("li.active",c).removeClass("active"),$(".selected",c).remove();var d=$(this).parents("li").last();d.addClass("current"),d.find("a:first").append('')}),$(".page-header").on("click",".search-form",function(a){$(this).addClass("open"),$(this).find(".form-control").focus(),$(".page-header .search-form .form-control").on("blur",function(a){$(this).closest(".search-form").removeClass("open"),$(this).unbind("blur")})}),$(".page-header").on("keypress",".hor-menu .search-form .form-control",function(a){return 13==a.which?($(this).closest(".search-form").submit(),!1):void 0}),$(".page-header").on("mousedown",".search-form.open .submit",function(a){a.preventDefault(),a.stopPropagation(),$(this).closest(".search-form").submit()}),$('[data-hover="megamenu-dropdown"]').not(".hover-initialized").each(function(){$(this).dropdownHover(),$(this).addClass("hover-initialized")}),$(document).on("click",".mega-menu-dropdown .dropdown-menu",function(a){a.stopPropagation()})},l=function(){$("body").on("shown.bs.tab",'a[data-toggle="tab"]',function(){d()})},m=function(){var a=300,b=500;navigator.userAgent.match(/iPhone|iPad|iPod/i)?$(window).bind("touchend touchcancel touchleave",function(c){$(this).scrollTop()>a?$(".scroll-to-top").fadeIn(b):$(".scroll-to-top").fadeOut(b)}):$(window).scroll(function(){$(this).scrollTop()>a?$(".scroll-to-top").fadeIn(b):$(".scroll-to-top").fadeOut(b)}),$(".scroll-to-top").click(function(a){return a.preventDefault(),$("html, body").animate({scrollTop:0},b),!1})},n=function(){var a,b=$(".full-height-content");if(a=Metronic.getViewPort().height-$(".page-header").outerHeight(!0)-$(".page-footer").outerHeight(!0)-$(".page-title").outerHeight(!0)-$(".page-bar").outerHeight(!0),b.hasClass("portlet")){var d=b.find(".portlet-body");if(Metronic.getViewPort().width\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_EXTRACTED_REPORTS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n\n'),a.put("app/analytic/metric/list/create.modal.html",'\n\n\n'),a.put("app/analytic/metric/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_METRICS\' | translate }} \n
\n
\n \n
\n \n
\n \n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/analytic/metric/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{metric.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/analytic/metric/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_METRIC\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'), +a.put("app/analytic/report/list/copy.modal.html",'\n\n\n'),a.put("app/analytic/report/list/create.modal.html",'\n\n\n'),a.put("app/analytic/report/list/extract.modal.html",'\n\n\n'),a.put("app/analytic/report/list/list.html",'\n
\n
\n \n
\n \n
\n
\n
\n \n {{ \'APPLICATION_FOLDERS\' | translate }} \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_REPORTS\' | translate }} - {{selectedNode}}\n
\n
\n \n
\n \n \n {{\'APPLICATION_IMPORT_FROM_JSON\' | translate}}\n \n \n
\n
\n \n
\n
\n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n \n
\n
\n
\n
\n\n'),a.put("app/analytic/report/list/preview.modal.html",'\n\n\n'),a.put("app/analytic/report/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{report.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/analytic/report/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_REPORT\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n\n
\n \n
\n
\n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n\n\n \n
\n\n
\n \n
\n
\n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n
\n \n {{ \'APPLICATION_FIELDS\' | translate}} \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{ \'APPLICATION_FIELD\' | translate }} / {{ \'APPLICATION_METRIC\' | translate }}{{ \'APPLICATION_ALIAS\' | translate }}{{ \'APPLICATION_FUNCTION\' | translate }}{{ \'APPLICATION_GROUP_BY\' | translate }}{{ \'APPLICATION_ORDER_BY\' | translate }}
\n \n
\n \n \n \n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n \n
\n \n
\n \n \n {{$select.selected.name | translate}}\n \n {{$translate.instant(groupBy.name)}}\n \n \n
\n \n
\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n
\n \n
\n \n \n \n
\n {{ \'MESSAGE_ADD_A_FIELD\' | translate }}\n
\n \n \n
\n
\n
\n
\n \n {{ \'APPLICATION_CONDITIONS\' | translate}} \n
\n
\n
\n Output
\n \n
\n\n \n
\n \n
\n
\n
\n
\n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/channels/chat/offline/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_VISITORS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/offline/view/view.detail.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_DETAIL\' | translate}}\n
\n
\n
\n
\n
\n

\n {{\'APPLICATION_MESSAGE\' | translate}}\n
\n

\n
\n \n
\n

\n {{chatVisitor.ChatEnquiry.text}}\n

\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/chat/offline/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{chatVisitor.ChatEnquiry.email}}\n
\n
\n {{chatVisitor.ChatEnquiry.username}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/online/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_VISITORS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/online/view/view.detail.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_DETAIL\' | translate}}\n
\n
\n \n
\n
\n
\n'), +a.put("app/channels/chat/online/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{chatRoom.ChatVisitor.email}}\n
\n
\n {{chatRoom.ChatVisitor.fullname}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/preview/preview.html",'\n
\n
\n \n \n \n \n \n {{statePreview.state == \'online\' ? chatWebsite.header_online : chatWebsite.header_offline}}\n
\n
\n
\n \n
\n
\n

\n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n
\n
\n \n
\n
\n

{{chatWebsite.rating_message}}

\n
\n
\n \n \n
\n
\n \n \n
\n \n \n
\n
\n \n
\n
\n'),a.put("app/channels/chat/queue/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/chat/queue/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_QUEUES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/queue/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/chat/queue/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{queue.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/queue/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{$select.selected.toUpperCase()}}\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n'),a.put("app/channels/chat/realtime/view/agent/agent.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/realtime/view/agent/agent.modal.info.html",'\n\n\n'),a.put("app/channels/chat/realtime/view/agent/queue.modal.add.html",'\n\n\n'),a.put("app/channels/chat/realtime/view/queue/queue.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'), +a.put("app/channels/chat/realtime/view/session/session.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/realtime/view/view.html",'\n\n\n'),a.put("app/channels/chat/visitor/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_VISITORS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/visitor/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{chatVisitor.fullname}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/visitor/view/view.profile.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_PROFILE\' | translate}}\n
\n
\n \n
\n
\n
\n'),a.put("app/channels/chat/website/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_WEB_SITES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/website/view/action/list/list.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/chat/website/view/action/view/view.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACTION\' | translate }} \n
\n
\n
\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n
\n \n
\n \n \n {{$select.selected.fullname}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n \n
\n \n \n {{ $select.selected.name | translate }}\n \n {{ intType.name | translate }}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n
\n
\n \n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate}}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate }}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{ $select.selected.name}}\n \n {{ interval.name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/website/view/action/wizard/wizard.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACTION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n
\n \n
\n \n \n {{$select.selected.fullname}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n \n
\n \n \n {{ $select.selected.name | translate }}\n \n {{ intType.name | translate }}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n
\n
\n \n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate}}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate }}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{ $select.selected.name}}\n \n {{ interval.name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n\n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'), +a.put("app/channels/chat/website/view/embedding/view/view.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_EMBEDDING\' | translate}}\n
\n \n
\n
\n
\n
\n

{{\'APPLICATION_EMBED_SNIPPET\' | translate}}

\n

\n {{\'MESSAGE_EMBED_SNIPPET\' | translate}}\n

\n
\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/channels/chat/website/view/form/view/view.html",'
\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_FIELDS_SELECTED\' | translate }}\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_FIELDS_AVAILABLE\' | translate }}\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_FIELDS_SELECTED\' | translate }}\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_FIELDS_AVAILABLE\' | translate }}\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/channels/chat/website/view/proactive/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/chat/website/view/proactive/list/list.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_PROACTIVE_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/chat/website/view/snippet/view/view.html",'
\n
\n
\n \n
\n
\n
\n
\n\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{$translate.instant(\'APPLICATION_\' + $select.selected.toUpperCase())}}\n \n
\n
\n
\n
\n \n\n \n
\n \n \n \n {{$select.selected ? \'On\' : \'Off\'}}\n \n
\n
\n
\n
\n \n\n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n {{$select.selected ? \'On\' : \'Off\'}}\n \n
\n
\n
\n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n

{{\'APPLICATION_ONLINE_STATE\' | translate}}

\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n

{{\'APPLICATION_RATING_STATE\' | translate}}

\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n

{{\'APPLICATION_OFFLINE_STATE\' | translate}}

\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n {{\'MESSAGE_REMEMBER_SMTP_SERVICE_ACCOUNT\' | translate}}.\n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n
\n
\n \n
\n \n \n \n {{$select.selected}}\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n'), +a.put("app/channels/chat/website/view/view.html",'\n\n\n'),a.put("app/channels/chat/website/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_WEB_SITE\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n\n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{$translate.instant(\'APPLICATION_\' + $select.selected.toUpperCase())}}\n \n
\n
\n
\n
\n \n\n \n
\n \n \n {{$select.selected ? \'On\' : \'Off\'}}\n \n
\n
\n
\n
\n \n\n\n \n
\n
\n\n \n
\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n
\n\n \n
\n \n \n {{$select.selected ? \'On\' : \'Off\'}}\n \n
\n
\n
\n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/account/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNTS\' | translate }} \n
\n \n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_PHONE\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{faxAccount.name}}{{faxAccount.description}}{{faxAccount.phone}}\n \n {{ \'APPLICATION_EDIT\' | translate }}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No fax account available\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/account/view/view.applications.html",'
\n
\n\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n {{$select.selected | uppercase}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n \n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'), +a.put("app/channels/fax/account/view/view.html",'\n
\n
\n \n\n\n\n\n \n
\n \n
\n \n
\n \n
\n \n\n \n
\n
\n {{ account.name || account.description }}\n
\n
\n {{ account.phone }}\n
\n
\n \n\n \n \n \n
\n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/account/view/view.routes.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ROUTES\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_APPLICATION\' | translate}}{{\'APPLICATION_ARGUMENTS\' | translate}}{{\'APPLICATION_TIMEOUT\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{application.app}} {{getAppdata(application.app, application.appdata)}}{{application.timeout}}\n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No applications available\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/fax/account/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/fax/account/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/inbox/inbox.html",'\n\n\n
\n
\n
\n
\n'),a.put("app/channels/fax/inbox/incoming/incoming.html",'\n
\n \n
\n

Inbox

\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n \n
\n
\n \n \n \n \n
\n \n {{$select.selected}}\n \n \n \n \n
\n
\n
\n \n \n {{faxRoom.from}}\n \n {{faxRoom.MailAccount.description ? faxRoom.MailAccount.description : faxRoom.MailAccount.name}}\n \n {{faxRoom.status | uppercase}} \n \n {{faxRoom.User.fullname}} \n {{\'APPLICATION_UNASSIGNED\' | translate}} \n \n \n
\n {{\'MESSAGE_NO_AVAILABLE_MESSAGES\' | translate}}\n
\n \n
\n
\n
\n'),a.put("app/channels/fax/inbox/room/room.html",'\n
\n
\n \n \n \n
\n
\n
\n
\n
    \n
  • \n \n
    \n \n \n {{\'APPLICATION_FROM\' | translate}}: \n {{faxMessage.From.fullname}} \n <{{faxMessage.From.phone}}> \n
    \n {{\'APPLICATION_TO\' | translate}}: \n {{faxMessage.To.fullname}} \n <{{faxMessage.To.phone}}> \n
    \n \n \n \n \n {{faxMessage.status | uppercase}} \n
    \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n
  • \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{ getCurrentUser().fullname }}\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n {{$select.selected.name}} - {{$select.selected.phone}}\n \n
\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n\n \n
\n
\n
\n
\n \n
\n
\n \n {{$item}}\n \n {{to}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n\n \n
\n
\n \n
\n
\n
\n \n\n \n
\n
\n \n \n \n \n \n \n \n \n \n
\n \n {{ item.file.name }}\n \n \n {{ item.file.size/1024/1024|number:2 }} MB\n \n \n
\n
\n
\n
\n \n \n
\n
\n
\n \n\n
\n
\n
\n
\n
\n
\n
\n\n'), +a.put("app/channels/fax/queue/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/fax/queue/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_QUEUES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/queue/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/fax/queue/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{queue.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/queue/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{$select.selected.toUpperCase()}}\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n'),a.put("app/channels/fax/realtime/view/agent/agent.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/realtime/view/agent/agent.modal.info.html",'\n\n\n'),a.put("app/channels/fax/realtime/view/agent/queue.modal.add.html",'\n\n\n'),a.put("app/channels/fax/realtime/view/view.html",'\n\n\n'),a.put("app/channels/mail/account/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNTS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/account/view/action/list/list.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/mail/account/view/action/view/view.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACTION\' | translate }} \n
\n
\n
\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n
\n \n
\n \n \n {{$select.selected.fullname}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n \n
\n \n \n {{ $select.selected.name | translate }}\n \n {{ intType.name | translate }}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n
\n
\n \n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate}}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate }}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{ $select.selected.name}}\n \n {{ interval.name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n
\n
\n \n
\n
\n\n'), +a.put("app/channels/mail/account/view/action/wizard/wizard.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACTION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n
\n \n
\n \n \n {{$select.selected.fullname}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n \n
\n \n \n {{ $select.selected.name | translate }}\n \n {{ intType.name | translate }}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n
\n
\n \n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate}}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate }}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{ $select.selected.name}}\n \n {{ interval.name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n\n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/account/view/view.html",'\n
\n
\n \n\n\n\n\n \n
\n \n
\n \n
\n \n
\n \n\n \n
\n
\n {{ account.description || account.name }}\n
\n
\n {{account.email}}\n
\n
\n \n\n \n \n \n
\n
\n \n
\n \n
\n\n
\n'),a.put("app/channels/mail/account/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'), +a.put("app/channels/mail/account/wizard/wizard.html",'\n
\n
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/inbox/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_INBOX\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/inbox/mail/mail.html",'
\r\n
\r\n
\r\n From: \r\n {{mailMessage.from}}\r\n
\r\n To: \r\n {{mailMessage.to}} \r\n
\r\n Cc: \r\n {{mailMessage.cc}} \r\n
\r\n
\r\n {{\'APPLICATION_SENT_BY\' | translate}}: {{mailMessage.User.fullname}}\r\n
\r\n
\r\n
\r\n \r\n \r\n {{mailMessage.status | uppercase}}\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n {{mailAttachment.name}}\r\n \r\n {{mailAttachment.size}}B \r\n \r\n {{ \'APPLICATION_DOWNLOAD\' | translate }}\r\n \r\n
\r\n
\r\n'),a.put("app/channels/mail/inbox/note/note.html",'
\r\n
\r\n
\r\n \r\n
\r\n
\r\n {{\'APPLICATION_ADD_BY\' | translate}}: {{mailMessage.User.fullname}}\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n {{mailAttachment.name}}\r\n \r\n {{mailAttachment.size}}B \r\n \r\n {{ \'APPLICATION_DOWNLOAD\' | translate }}\r\n \r\n
\r\n
\r\n'),a.put("app/channels/mail/inbox/view/view.agents.modal.html",'\n\n\n'),a.put("app/channels/mail/inbox/view/view.html",'
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n'),a.put("app/channels/mail/inbox/view/view.notes.modal.html",'\n\n\n'),a.put("app/channels/mail/inbox/view/view.room.html",'\n
\n
\n
\n
\n \n {{mailRoom.status}} - {{mailRoom.subject}}\n
\n
\n
\n \n
\n
\n \n
\n
\n \n
\n
\n \n \n \n
\n
\n
\n
\n
\n
\n
\n
    \n
  • \n \n \n \n
  • \n
\n
\n
\n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
\n \n {{$select.selected.name}}\n \n
\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n {{$item}}\n \n {{to}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n {{$item}}\n \n {{cc}}\n \n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n
{{ item.file.name }}{{ item.file.size/1024/1024|number:2 }} MB\n
\n
\n
\n
\n \n \n \n \n \n
\n
\n
\n
\n
\n
\n \n \n
\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n\n'), +a.put("app/channels/mail/inbox/view/view.templates.modal.html",'\n\n\n'),a.put("app/channels/mail/queue/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/mail/queue/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_QUEUES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/queue/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_AVAILABLE_TEAMS\' | translate }}\n

\n
\n
\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/mail/queue/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{queue.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n \n'),a.put("app/channels/mail/queue/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected.toUpperCase()}}\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n'),a.put("app/channels/mail/realtime/view/agent/agent.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/realtime/view/agent/agent.modal.info.html",'\n\n\n'),a.put("app/channels/mail/realtime/view/agent/queue.modal.add.html",'\n\n\n'),a.put("app/channels/mail/realtime/view/queue/queue.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/realtime/view/session/session.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/realtime/view/view.html",'\n\n\n'),a.put("app/channels/mail/realtime/view/view.queue.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/chanspy/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/voice/chanspy/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_CHANSPY\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/chanspy/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{chanspy.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/chanspy/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_CHANSPY\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item.value}}: {{$item.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'), +a.put("app/channels/voice/context/list/create.modal.html",'\n\n\n'),a.put("app/channels/voice/context/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_CONTEXTS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/context/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{context.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n \n'),a.put("app/channels/voice/context/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_CONTEXT\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_CANT_EDIT_NAME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/moh/list/create.modal.html",'\n\n\n'),a.put("app/channels/voice/moh/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_MOHS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/moh/view/view.addFiles.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_MOH\' | translate }} {{ \'APPLICATION_ADD_FILES\' | translate }} \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n
\n\n \n
\n \n \n {{$item.display_name}}\n \n {{sound.display_name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/moh/view/view.audios.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_AUDIOS\' | translate}}\n
\n \n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_FOLDER_DOES_NOT_EXIST\' | translate }}\n

\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_PREVIEW\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{audiofile}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n {{ \'MESSAGE_NO_AUDIOFILES_AVAILABLE\' | translate }}\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/moh/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{moh.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/moh/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_MOH_CLASS\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(sort.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/queue/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/voice/queue/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_QUEUES\' | translate }}\n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/queue/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n

Warning!

{{ \'MESSAGE_NO_AVAILABLE_TEAMS\' | translate }}

\n
\n
\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/voice/queue/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{queue.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/queue/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_QUEUE_SETTINGS\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n
\n
\n \n
\n \n \n {{$select.selected.toUpperCase()}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_STRATEGY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_VOICE_MOH\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_TIMEOUT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_MAXLEN\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_RETRY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_WRAPUPTIME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_WEIGHT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_JOINEMPTY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_LEAVEWHENEMPTY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n
\n \n\n \n
\n
\n\n
\n
\n
\n
\n \n
\n \n \n {{$item.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{ \'DESCRIPTION_QUEUE_PERIODIC_ANNOUNCE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n
\n
\n

{{\'APPLICATION_SETTINGS\' | translate}}

\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE_FREQUENCY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_MIN_ANNOUNCE_FREQUENCY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_PERIODIC_ANNOUNCE_FREQUENCY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_RANDOM_PERIODIC_ANNOUNCE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE_HOLDTIME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE_POSITION\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE_POSITION_LIMIT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_REPORTHOLDTIME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n

{{\'APPLICATION_SOUNDS\' | translate}}

\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_REPORTHOLD\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_YOUARENEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_THEREARE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_CALLSWAITING\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_HOLDTIME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_MINUTES\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_MINUTE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_SECONDS\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_THANKYOU\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n
\n \n \n
\n
\n\n
\n
\n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_AUTOPAUSE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_RINGINUSE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_MEMBER_DELAY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n {{ \'DESCRIPTION_ACW\' | translate }}\n \n \n {{\'APPLICATION_ACW\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_TIMEOUTRESTART\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_MONITOR_FORMAT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_ACW_TIMEOUT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'), +a.put("app/channels/voice/realtime/view/agent/agent.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/realtime/view/agent/agent.modal.info.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/agent/queue.modal.add.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/areport/report.html",'\n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_UNIQUEID\' | translate }}{{ \'APPLICATION_QUEUE\' | translate }}{{ \'APPLICATION_AGENT\' | translate }}{{ \'APPLICATION_CALLER\' | translate }}{{ \'APPLICATION_CALLED_AT\' | translate }}{{ \'APPLICATION_CONNECTED_AT\' | translate }}{{ \'APPLICATION_COMPLETED_AT\' | translate }}{{ \'APPLICATION_REASON\' | translate }}{{ \'APPLICATION_HOLDTIME\' | translate }}{{ \'APPLICATION_TALKTIME\' | translate }}
\n {{agent.uniqueid}}{{agent.queue}}{{agent.destcalleridname ? agent.destcalleridname + \' [\' + agent.membername + \']\' : agent.membername }}{{agent.calleridname ? agent.calleridname + \' [\' + agent.calleridnum + \']\' : agent.calleridnum }}\n \n \n \n \n \n \n {{agent.reason | uppercase}}\n {{agent.holdtime || 0 | VoiceRealtimeViewAgentReportFilter | date:\'HH:mm:ss\'}}{{agent.talktime || 0 | VoiceRealtimeViewAgentReportFilter | date:\'HH:mm:ss\'}}
\n No agents available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n
\n\n'),a.put("app/channels/voice/realtime/view/qreport/report.html",'\n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_UNIQUEID\' | translate }}{{ \'APPLICATION_QUEUE\' | translate }}{{ \'APPLICATION_AGENT\' | translate }}{{ \'APPLICATION_CALLER\' | translate }}{{ \'APPLICATION_CALLED_AT\' | translate }}{{ \'APPLICATION_CONNECTED_AT\' | translate }}{{ \'APPLICATION_ABANDONED_AT\' | translate }}
\n {{queue.uniqueid}}{{queue.queue}}{{queue.connectedlinename ? queue.connectedlinename + \' [\' + queue.connectedlinenum + \']\' : queue.connectedlinenum }}{{queue.calleridname ? queue.calleridname + \' [\' + queue.calleridnum + \']\' : queue.calleridnum }}\n \n \n \n \n \n
\n No queues available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n
\n\n'),a.put("app/channels/voice/realtime/view/queue/pause.modal.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/queue/queue.add.modal.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/queue/queue.html",'\n
\n
\n
Selection from a modal: {{ selected }}
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
{{ \'APPLICATION_QUEUE\' | translate }}{{ \'APPLICATION_AGENT\' | translate }}{{ \'APPLICATION_LAST_LOGIN\' | translate }}{{ \'APPLICATION_LAST_PAUSE\' | translate }}{{ \'APPLICATION_LAST_INCOMING_CALL\' | translate }}{{ \'APPLICATION_SERVED\' | translate }}
{{group.queue}}\n \n \n \n \n {{agent.membername}}\n \n \n \n \n \n {{agent.paused ? \'(\' + agent.reason + \')\' : \'\'}}\n \n \n \n {{agent.callstaken}}\n \n \n \n \n \n \n \n
\n \n \n \n \n {{agent.membername}}\n \n \n \n \n \n {{agent.paused ? \'(\' + agent.reason + \')\' : \'\'}}\n \n \n \n {{agent.callstaken}}\n \n \n \n
\n \n \n \n \n {{agent.membername}}\n \n \n \n \n \n {{agent.paused ? \'(\' + agent.reason + \')\' : \'\'}}\n \n \n \n {{agent.callstaken}}\n \n \n \n
\n No agents available\n
\n
\n \n \n
\n
\n \n
\n \n
\n\n
\n\n'),a.put("app/channels/voice/realtime/view/queue/queue.modal.add.html",'\n\n\n'), +a.put("app/channels/voice/realtime/view/queue/queue.modal.remove.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/queue/queue.remove.modal.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/view.html",'\n\n\n'),a.put("app/channels/voice/recording/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_RECORDINGS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/inbound/list/create.modal.html",'\n\n\n\n'),a.put("app/channels/voice/route/inbound/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_INBOUND\' | translate }} {{ \'APPLICATION_ROUTES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/inbound/view/view.applications.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/inbound/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{route.exten}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n \n
\n
\n\n"),a.put("app/channels/voice/route/inbound/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_INBOUND\' | translate}} {{ \'APPLICATION_ROUTE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/internal/list/create.modal.html",'\n\n\n\n'),a.put("app/channels/voice/route/internal/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_INTERNAL\' | translate }} {{ \'APPLICATION_ROUTES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/internal/view/view.applications.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/internal/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{route.exten}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n \n
\n
\n\n"),a.put("app/channels/voice/route/internal/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_INTERNAL\' | translate}} {{ \'APPLICATION_ROUTE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/outbound/list/create.modal.html",'\n\n\n\n'), +a.put("app/channels/voice/route/outbound/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_OUTBOUND\' | translate }} {{ \'APPLICATION_ROUTES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/outbound/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{route.exten}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n \n
\n
\n\n"),a.put("app/channels/voice/route/outbound/view/view.route.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_NEW_ROUTE\' | translate }} WIZARD \n
\n
\n
\n
\n {{(main.app | capitalize) || \'Application\'}}\n
\n \n \n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_TRUNKS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_TRUNKS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n \n
\n \n \' placeholder=\'"name" \' class="form-control" data-ng-model="application.appdata[1]" data-ng-init="application.appdata[1] = null">\n \n {{ \'DESCRIPTION_OUTBOUND_CALLERID\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_OUTBOUND_PREFIX\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n
\n \n
\n \n \n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(intType.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(interval.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/outbound/view/view.routeSettings.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_APPLICATION_SETTINGS\' | translate }} WIZARD \n
\n
\n
\n \n
\n {{(main.app | capitalize) || \'Application\'}}\n
\n \n
\n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_TRUNKS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_TRUNKS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n \n \n\n \n
\n \n \' placeholder=\'"name" \' class="form-control" data-ng-model="route.Applications[selectedApp].appdata[1]">\n \n {{ \'DESCRIPTION_OUTBOUND_CALLERID\' | translate }} "name" <number>\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_OUTBOUND_PREFIX\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n
\n \n
\n \n \n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(intType.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(interval.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'), +a.put("app/channels/voice/route/outbound/view/view.routes.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/outbound/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_OUTBOUND\' | translate}} {{ \'APPLICATION_ROUTE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/view.application.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_NEW_APPLICATION\' | translate }} WIZARD \n
\n
\n
\n \n
\n {{(main.app | capitalize) || \'Application\'}}\n
\n \n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_QUEUES_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_QUEUES\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_PROJECTS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_PROJECTS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n {{$select.selected.mailbox}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_VOICEMAILS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_VOICEMAILS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n
\n \n
\n \n \n \n
\n \n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(interval.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n\n'), +a.put("app/channels/voice/route/view.applicationSettings.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_APPLICATION_SETTINGS\' | translate }} WIZARD \n
\n
\n
\n \n
\n {{(main.app | capitalize) || \'Application\'}}\n
\n \n
\n\n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_QUEUES_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_QUEUES\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$translate.instant($item.name)}}\n \n {{$translate.instant(queueOpt.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(audioOpt.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_PROJECTS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_PROJECTS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n \n \n\n
\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(hangupCause.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n {{$select.selected.mailbox}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_VOICEMAILS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_VOICEMAILS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n
\n \n
\n \n \n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(intType.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(interval.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'), +a.put("app/channels/voice/voicemail/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_VOICEMAILS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/voicemail/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{voicemail.mailbox}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/voicemail/view/view.messages.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_MESSAGES\' | translate}}\n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/voice/voicemail/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_VOICEMAIL\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n \n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/voicemail/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_VOICEMAIL\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n'),a.put("app/contactmanager/company/list/create.modal.html",'\n\n\n'),a.put("app/contactmanager/company/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_COMPANIES\' | translate }} \n
\n
\n \n
\n \n
\n \n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/contactmanager/company/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{company.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/contactmanager/company/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_COMPANY\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n
\n
\n
\n
\n'), +a.put("app/contactmanager/contact/list/import.modal.html",'\n\n\n'),a.put("app/contactmanager/contact/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_CONTACTS\' | translate }} \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_IMPORT_FROM_CSV\' | translate}}\n \n \n
\n \n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/contactmanager/service/list/create.modal.html",'\n\n\n'),a.put("app/contactmanager/service/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_SERVICES\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/contactmanager/service/view/create.modal.html",'\n\n\n'),a.put("app/contactmanager/service/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_AVAILABLE_TEAMS\' | translate }}\n

\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/contactmanager/service/view/view.customFieldSettings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_CUSTOM_FIELD\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n
\n\n
\n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n \n\n
\n\n \n
\n \n \n
\n \n \n
\n\n
\n
\n
\n
\n'),a.put("app/contactmanager/service/view/view.customFields.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CUSTOM_FIELDS\' | translate}}\n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/contactmanager/service/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{service.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'), +a.put("app/contactmanager/service/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_SERVICE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/dashboard/dashboard.html",'\n
\n
\n
\n \n
\n
\n
\n
\n\n'),a.put("app/dashboard/mail/mail.html",'
\nThis is the mail view.\n
\n'),a.put("app/dashboard/voice/voice.html",'
\n
\n
\n test\n
\n
\n
\n
\n \n {{ \'APPLICATION_INBOUND\' | translate }}\n \n\n
\n
\n
\n
\n \n
\n
\n
\n {{waiting || 0}}\n
\n
\n {{\'APPLICATION_WAITING\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{active || 0}}\n
\n
\n {{\'APPLICATION_ACTIVE\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{answered || 0}}\n
\n
\n {{\'APPLICATION_ANSWERED\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{abandoned || 0}}\n
\n
\n {{\'APPLICATION_ABANDONED\' | translate}}\n
\n
\n
\n
\n
\n\n
\n
\n
\n
\n \n
\n
\n
\n {{avganswertime || 0}}\n
\n
\n {{\'APPLICATION_AVG_ANSWER_TIME\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{avgtalktime || 0}}\n
\n
\n {{\'APPLICATION_AVG_TALK_TIME\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{answerrate || 0}}\n
\n
\n {{\'APPLICATION_ANSWER_RATE\' | translate}} (%)\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{abandonrate || 0}}\n
\n
\n {{\'APPLICATION_ABANDON_RATE\' | translate}} (%)\n
\n
\n
\n
\n
\n\n
\n
\n
\n
\n \n
\n
\n
\n {{totaloffered || 0}}\n
\n
\n {{\'APPLICATION_TOTAL_OFFERED\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{unmanaged || 0}}\n
\n
\n {{\'APPLICATION_UNMANAGED\' | translate}}\n
\n
\n
\n
\n
\n
\n\n
\n \n {{ \'APPLICATION_OUTBOUND\' | translate }}\n \n\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutbound || 0}}\n
\n
\n {{\'APPLICATION_MANUAL_OUTBOUND\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutboundglobalduration || 0}}\n
\n
\n {{\'APPLICATION_GLOBAL_DURATION\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutboundanswered || 0}}\n
\n
\n {{\'APPLICATION_ANSWERED\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutboundavgduration || 0}}\n
\n
\n {{\'APPLICATION_AVG_DURATION\' | translate}} (%)\n
\n
\n
\n
\n
\n\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutboundanswerrate || 0}}\n
\n
\n {{\'APPLICATION_ANSWER_RATE\' | translate}} (%)\n
\n
\n
\n
\n
\n\n
\n
\n
\n'),a.put("app/desk/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_DESK_COM\' | translate }} \n
\n \n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_EMAIL\' | translate }}{{ \'APPLICATION_REMOTE_ADDRESS\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{account.name}}{{account.username}}{{account.remoteUri}}{{account.description}}\n \n {{ \'APPLICATION_EDIT\' | translate }}\n \n \n {{ \'APPLICATION_CHECK_CONNECTION\' | translate }}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No account available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/desk/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/desk/view/view.configuration.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_CONFIGURATION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/desk/view/view.configurationSettings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n \n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n
\n
\n
\n
\n
\n'), +a.put("app/desk/view/view.configurations.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_DESCRIPTION\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{configuration.name}}{{configuration.description}}\n \n {{ \'APPLICATION_SETTINGS\' | translate}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No configuration available\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/desk/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/desk/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_DOMAIN\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/freshdesk/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_FRESHDESK\' | translate }} \n
\n \n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_EMAIL\' | translate }}{{ \'APPLICATION_REMOTE_ADDRESS\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{account.name}}{{account.username}}{{account.remoteUri}}{{account.description}}\n \n {{ \'APPLICATION_EDIT\' | translate }}\n \n \n {{ \'APPLICATION_CHECK_CONNECTION\' | translate }}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No account available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/freshdesk/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/freshdesk/view/view.configuration.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_CONFIGURATION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/freshdesk/view/view.configurationSettings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n \n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected[0]}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n
\n
\n
\n
\n
\n'), +a.put("app/freshdesk/view/view.configurations.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_DESCRIPTION\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{configuration.name}}{{configuration.description}}\n \n {{ \'APPLICATION_SETTINGS\' | translate}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No configuration available\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/freshdesk/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/freshdesk/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_DOMAIN\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/integration/list/list.html",'\n\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_INTEGRATIONS\' | translate }} \n
\n
\n \n New App \n \n \n \n \n \n
\n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_ID\' | translate }}{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_FILENAME\' | translate }}{{ \'APPLICATION_VERSION\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{integration.id}}{{integration.name}}{{integration.filename}}{{integration.version}}{{integration.description}}\n \n {{ \'APPLICATION_UPDATE\' | translate }} \n \n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No integrations available\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n \n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/jscripty/project/list/list.create.modal.html",'\n\n\n'),a.put("app/jscripty/project/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_PROJECTS\' | translate }} \n
\n \n
\n
\n \n\n \n\n\n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/jscripty/project/report/report.detail.html",'
\n
\n \n
\n\n
\n
\n
\n
\n
\n Questions Detail\n
\n \n
\n
\n
\n
\n
\n {{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}\n\n
\n
\n
\n

\n Question Id: {{id}}\n

\n\n
\n
\n
\n
\n
\n

\n {{label}}\n

\n\n
\n
\n
\n
\n

\n \n\n

\n {{question}}\n
\n
\n
\n \n \n \n \n \n \n \n \n \n\n \n \n\n \n\n \n
Answer Count
{{answer.question_answer || \'No answer\'}}{{answer.count}}
\n
\n
\n\n
\n
\n
\n\n\n
\n\n\n
\n
\n \n
\n\n
\n\n
\n
\n\n
\n\n
\n\n
\n
\n
\n'),a.put("app/jscripty/project/report/report.html",'\n
\n
\n\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n\n
\n
\n \n\n \n \n \n\n
\n\n
\n\n
\n
\n
\n
\n
\n
\n
\n

{{projectStats.started}}

\n Started\n
\n
\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n

{{projectStats.incomplete}}

\n Incomplete\n
\n
\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n

{{projectStats.completed}}

\n Completed\n
\n
\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n\n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/jscripty/project/report/report.session.detail.html",'\n\n
\n
\n
\n
\n
\n Session Detail\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n

\n

\n Session Id: {{sessionQuestions.session_id}}

\n

\n

\n

\n Status: {{sessionQuestions.status}}

\n

\n

\n

\n Started At: {{sessionQuestions.createdAt}}

\n

\n

\n

\n Closed At: {{sessionQuestions.completedAt}}

\n

\n
\n\n
\n\n
\n
\n

\n \n {{question.question_label}} [ID : {{question.question_id}}]

\n\n
\n
\n\n
\n
\n

Question:

{{question.question_text}}\n
\n
\n
\n
\n

Answer:

{{question.question_answer}}\n
\n
\n
\n

\n \n {{question.question_other_label}}: \n

\n {{question.question_other_answer}}\n
\n
\n\n\n
\n
\n \n \n \n \n \n \n \n \n\n \n\n \n \n\n \n\n \n
Label Answer
{{input.input_label}}{{input.input_value || \'No Answer\'}}
\n\n
\n
\n
\n
\n
\n\n
\n\n
\n\n
\n
\n
\n'), +a.put("app/jscripty/project/report/report.sessions.html",'\n\n
\n
\n \n
\n
\n
\n Project Sessions\n
\n
\n \n \n
\n
\n
\n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n\n
\n
\n
\n \n
\n
\n\n'),a.put("app/jscripty/project/report/report.summary.html",'
\n
\n
\n
\n
\n
\n Questions Summary\n\n
\n
\n \n \n
\n
\n
\n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n\n
\n\n
\n\n
\n
\n
\n
\n'),a.put("app/jscripty/project/view/view.html",'\n\n
\n
\n
\n
\n
\n\n\n'),a.put("app/login/login.html",'\n\n\n\n
\n \n \n
\n\n\n'),a.put("app/main/chooseContact.modal.html",'\n\n\n'),a.put("app/main/closeEditedTab.modal.html",'\n\n\n'),a.put("app/main/main.html",'\n\n\n\n
\n
\n\n
\n\n \n
\n
\n \n\n \n
\n
\n\n \n \n \n \n Motion \n \n
\n
\n \n \n {{workspace.name}} \n \n
\n \n \n \n
\n
\n
\n \n\n
\n
\n \n\n \n \n
\n
\n \n\n
\n\n\n\n\n\n\n\n\n\n\n\n'),a.put("app/main/template/actionBuilder/template.actionBuilderIntegration.html",'
\n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n \n'+" {{'APPLICATION_WARNING' | translate}}! {{'MESSAGE_REQUIRED_FIELD' | translate}}.\n \n
\n"),a.put("app/main/template/actionBuilder/template.actionBuilderStatus.html",'
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n'+" {{'APPLICATION_WARNING' | translate}}! {{'MESSAGE_REQUIRED_FIELD' | translate}}.\n \n
\n"),a.put("app/main/template/actionBuilder/template.actionBuilderTemplate.html",'
\n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n
\n'),a.put("app/main/template/template.conditionBuilder.html",'
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n'+" {{'APPLICATION_WARNING' | translate}}! {{'MESSAGE_REQUIRED_FIELD' | translate}}.\n \n
\n"),a.put("app/main/template/template.contactTab.html",'
\n
\n
\n \n
\n \n
\n
\n \n
\n
\n
\n \n
\n

{{\'MESSAGE_INBOUND_CALL_FROM\' | translate}} - {{data.calleridnum}}

\n

\n {{\'MESSAGE_CALL_UNIQUEID\' | translate}} : {{data.uniqueid}}\n

\n
\n
\n
\n
\n
\n {{\'APPLICATION_QUEUE\' | translate}} \n {{workspace.data.queue}} \n
\n
\n
\n
\n {{\'APPLICATION_AGENT\' | translate}} \n {{workspace.data.membername}} \n
\n
\n
\n
\n {{\'APPLICATION_DATE\' | translate}} \n {{workspace.data.agentcalledAt}} \n
\n
\n
\n \n \n
\n
\n
\n \n {{\'APPLICATION_DETAIL\' | translate}}\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_COMPANIES_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_COMPANIES\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n {{$item}}\n \n {{tag}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n
\n
\n \n
\n \n \n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n \n {{\'APPLICATION_CUSTOM_FIELDS\' | translate}}\n
\n
\n
\n
\n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n {{$select.selected.value}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n
\n
\n \n
\n
\n \n
\n
\n
\n \n {{\'APPLICATION_LOG\' | translate}}\n
\n \n
\n
\n \n
\n
\n
\n
\n
\n \n \n
|\n
\n \n \n
|\n
\n \n \n
\n
\n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n
\n
\n
\n
\n
\n
\n \n \n
|\n
\n \n \n
|\n
\n \n \n
\n
\n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n
\n
\n
\n \n
\n
\n \n
\n \n \n
\n
\n
\n'), +a.put("app/main/template/template.jscriptyTab.html",'
\n\n \n
\n
\n \n
\n \n \n
\n \n
\n \n \n
\n \n
\n
\n
\n\n
\n \n {{attribute.value}} \n\n
\n\n\n
\n
\n
\n
\n
\n
\n\n \n
\n

{{attribute.value}}

\n
\n \n\n
\n
\n \n
\n
\n\n\n \n\n
\n
\n \n
\n
\n \n
\n\n
\n \n\n
\n
\n
\n
\n
\n \n\n
\n\n
\n \n \n \n \n\n
\n\n
\n
\n
\n\n
\n\n
\n \n
\n
\n \n\n
\n
\n \n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n'),a.put("app/main/template/template.reportBuilderView.html",'
\n
\n \n \n \n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.field | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n
\n
\n
\n
\n'),a.put("app/market/market.html",'
\n
\n \n
\n
\n\n
\n
\n \n
\n

Our Integrations

\n
\n
\n
\n
\n

{{integration.name}} {{integration.author}}

\n {{integration.name}}\n
\n

\n {{integration.description}}\n

\n \n
\n
\n
\n {{status}}\n
\n
\n
\n
\n
\n \n \n
\n
\n'),a.put("app/motionbar/motionbar.chat.html",'
\n'),a.put("app/salesforce/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_SALESFORCE\' | translate }} \n
\n \n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_EMAIL\' | translate }}{{ \'APPLICATION_REMOTE_ADDRESS\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{account.name}}{{account.username}}{{account.remoteUri}}{{account.description}}\n \n {{ \'APPLICATION_EDIT\' | translate }}\n \n \n {{ \'APPLICATION_CHECK_CONNECTION\' | translate }}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No account available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/salesforce/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/salesforce/view/view.configuration.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_CONFIGURATION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/salesforce/view/view.configurationSettings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n \n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n
\n
\n
\n
\n
\n'), +a.put("app/salesforce/view/view.configurations.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_DESCRIPTION\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{configuration.name}}{{configuration.description}}\n \n {{ \'APPLICATION_SETTINGS\' | translate}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No configuration available\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/salesforce/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/salesforce/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/setting/license/view/view.html",'\n\n
\n \n\n \n
\n
\n
\n
\n
\n

{{\'APPLICATION_MONTH_TO_MONTH\' | translate}}{{license.token || \'unknown\'}}

\n

{{\'APPLICATION_YEARLY\' | translate}}{{license.token || \'unknown\'}}

\n

{{\'APPLICATION_PERPETUAL\' | translate}}{{license.token || \'unknown\'}}

\n

{{\'APPLICATION_UNKNOWN\' | translate}}{{license.token || \'unknown\'}}

\n

{{license.expiration ? (license.expiration | date:\'medium\') : \'DEMO\'}}\n Expiration Date \n

\n
\n
    \n
  • \n
    \n {{\'APPLICATION_USERS\' | translate}}:\n
    \n
    \n {{(license.users || license.users >= 0) ? license.users : \'unknown\'}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_AGENTS\' | translate}} ({{\'APPLICATION_CONCURRENTS\' | translate}}):\n
    \n
    \n {{(license.agents || license.agents >= 0) ? license.agents : \'unknown\'}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_TELEPHONES\' | translate}}:\n
    \n
    \n {{(license.telephones || license.telephones >= 0) ? license.telephones : \'unknown\'}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_CHAT\' | translate}}:\n
    \n
    \n {{license.chat ? \'APPLICATION_ENABLED\' : \'APPLICATION_DISABLED\' | translate}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_MAIL\' | translate}}:\n
    \n
    \n {{license.mail ? \'APPLICATION_ENABLED\' : \'APPLICATION_DISABLED\' | translate}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_FAX\' | translate}}:\n
    \n
    \n {{license.fax ? \'APPLICATION_ENABLED\' : \'APPLICATION_DISABLED\' | translate}}\n
    \n
  • \n
\n \n
\n
\n
\n
\n
\n
\n \n FORM {{ \'APPLICATION_LICENSE\' | translate }} \n
\n
\n
\n
\n\n \n
\n \n
\n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/setting/smtp/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n \n
\n \n
\n \n
\n
\n\n'),a.put("app/setting/update/list/landing.html",'\n
\n
\n \n \n
\n
\n
\n {{countdown}}\n
\n
\n

Wait! We need to restart xCALLY Motion server.

\n

\n We are updatig it!
\n xCALLY Motion Team

\n

\n
\n
\n
\n \n
\n
\n\n'),a.put("app/setting/update/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_UPDATES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n \n
\n
\n
\n\n'),a.put("app/setting/update/list/list.pull.html",'\n\n\n'),a.put("app/square/odbc/list/list.create.modal.html",'\n\n\n'), +a.put("app/square/odbc/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_ODBCS\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/square/odbc/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{odbc.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/square/odbc/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ODBC\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n

Es. DRIVER=MySQL;SERVER=127.0.0.1;UID=xcall;PWD=password;DATABASE=motion

\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/square/project/list/list.create.modal.html",'\n\n\n'),a.put("app/square/project/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_PROJECTS\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/square/project/view/view.html",'\n\n
\n
\n
\n
\n
\n\n\n'),a.put("app/staff/agent/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_AGENTS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/agent/view/view.account.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_FORMAT\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n \n \n\n \n
\n
\n \n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{ \'APPLICATION_SELECT_IMAGE\' | translate }} \n
\n
\n \n \n
\n

\n
{{ \'MESSAGE_SUPPORTED_FORMATS\' | translate }} jpg, png, jpeg.\n

\n
\n
\n
\n
\n
\n \n \n \n \n \n \n \n \n
\n \n {{ item.file.name }}\n \n \n {{ item.file.size/1024/1024|number:2 }} MB\n \n \n
\n
\n
\n
\n \n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/view/view.chat.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_CHAT\' | translate}}\n
\n
\n\n
\n \n
\n \n
\n \n \n \n {{\'MESSAGE_ZERO_MEANS_UNLIMITED\' | translate}}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/view/view.fax.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_FAX\' | translate}}\n
\n
\n\n
\n \n
\n \n
\n \n \n \n {{\'MESSAGE_ZERO_MEANS_UNLIMITED\' | translate}}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/view/view.html",'\n
\n \n
\n\n'),a.put("app/staff/agent/view/view.mail.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_MAIL\' | translate}}\n
\n
\n\n
\n \n
\n \n
\n \n \n \n {{\'MESSAGE_ZERO_MEANS_UNLIMITED\' | translate}}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n
\n
\n
\n
\n
\n'), +a.put("app/staff/agent/view/view.phonebar.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_PHONE_BAR\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n \n
\n
\n \n
\n \n \n
\n \n\n \n
\n \n \n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/view/view.voice.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_VOICE\' | translate}}\n
\n
\n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{transport}}\n \n \n \n {{ \'DESCRIPTION_VOICE_TRANSPORT\' | translate }}\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_VOICE_HOST\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{nat}}\n \n \n \n {{ \'DESCRIPTION_VOICE_NAT\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_TYPE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{allow}}\n \n \n \n {{ \'DESCRIPTION_VOICE_CODEC\' | translate }}\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_AGENT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INVALID_PATTERN_NAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_FORMAT\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n
\n\n \n
\n \n \n {{$item}}\n \n {{transport}}\n \n \n \n {{ \'DESCRIPTION_VOICE_TRANSPORT\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{allow}}\n \n \n \n {{ \'DESCRIPTION_VOICE_CODEC\' | translate }}\n \n
\n \n\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n'),a.put("app/staff/team/list/create.modal.html",'\n\n\n'),a.put("app/staff/team/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TEAMS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/team/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n \n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n \n \n
\n
\n
\n
\n'),a.put("app/staff/team/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{team.name}}\n
\n\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n \n
\n
\n\n'),a.put("app/staff/team/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_ACCOUNT\' | translate}}\n
\n
\n\n
\n \n
\n\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n'),a.put("app/staff/telephone/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TELEPHONES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'), +a.put("app/staff/telephone/view/view.account.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_INTERNAL\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n {{$item}}\n \n {{transport}}\n \n \n \n {{ \'DESCRIPTION_VOICE_TRANSPORT\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{allow}}\n \n \n \n {{ \'DESCRIPTION_VOICE_CODEC\' | translate }}\n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n \n \n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/telephone/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{item.fullname}}\n
\n
\n {{item.role}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/telephone/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TELEPHONE\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INVALID_PATTERN_NAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_INTERNAL\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n
\n\n \n
\n \n \n {{$item}}\n \n {{transport}}\n \n \n \n {{ \'DESCRIPTION_VOICE_TRANSPORT\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{allow}}\n \n \n \n {{ \'DESCRIPTION_VOICE_CODEC\' | translate }}\n \n
\n \n\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n'),a.put("app/staff/user/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_USERS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/user/view/view.account.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_FORMAT\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{ \'APPLICATION_SELECT_IMAGE\' | translate }} \n
\n
\n \n \n
\n

\n
{{ \'MESSAGE_SUPPORTED_FORMATS\' | translate }} jpg, png, jpeg.\n

\n
\n
\n
\n
\n
\n \n \n \n \n \n \n \n \n
\n \n {{ item.file.name }}\n \n \n {{ item.file.size/1024/1024|number:2 }} MB\n \n \n
\n
\n
\n
\n \n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'), +a.put("app/staff/user/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{user.fullname}}\n
\n
\n {{user.role}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/user/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_USER\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INVALID_PATTERN_NAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_FORMAT\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n'),a.put("app/sugarcrm/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_SUGARCRM\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/sugarcrm/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/sugarcrm/view/view.configuration.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_CONFIGURATION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/sugarcrm/view/view.configurationSettings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n \n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n
\n
\n
\n
\n
\n'),a.put("app/sugarcrm/view/view.configurations.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_DESCRIPTION\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{configuration.name}}{{configuration.description}}\n \n {{ \'APPLICATION_SETTINGS\' | translate}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No configuration available\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/sugarcrm/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'), +a.put("app/sugarcrm/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_DOMAIN\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/tools/answer/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/answer/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_CANNED_ANSWERS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/answer/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{answer.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/answer/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_CANNED_ANSWER\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/automation/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_AUTOMATIONS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/automation/view/view.html",'\n
\n
\n \n\n\n\n\n \n
\n \n
\n \n
\n \n
\n \n\n \n
\n
\n {{ automation.name }}\n
\n
\n {{ automation.description }}\n
\n
\n \n\n \n \n \n
\n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/automation/view/view.settings.html",'
\n
\n
\n \n
\n \n
\n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ACTIONS\' | translate }}:\n
\n
\n
\n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n \n
\n \n
\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_CONDITION\' | translate}}.\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_ACTION\' | translate}}.\n \n
\n \n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/tools/automation/wizard/wizard.html",'
\n
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_AUTOMATIONS\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n \n {{ \'APPLICATION_CHANNEL\' | translate }}\n
\n
\n
\n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ACTIONS\' | translate }}:\n
\n
\n
\n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n \n
\n \n
\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_CONDITION\' | translate}}.\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_ACTION\' | translate}}.\n \n
\n \n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'), +a.put("app/tools/interval/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/interval/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_INTERVALS\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/interval/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{interval.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n"),a.put("app/tools/interval/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_INTERVAL\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/interval/view/view.subinterval.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_NEW_SUBINTERVAL\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n\n\n\n \n
\n
\n\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/tools/interval/view/view.subintervalSettings.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_SUBINTERVAL_SETTINGS\' | translate }} WIZARD \n
\n
\n
\n \n
\n {{subinterval.name}}\n
\n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n\n\n\n \n
\n
\n\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/tools/interval/view/view.subintervals.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_SUBINTERVALS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/tools/pause/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/pause/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_PAUSES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/pause/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{pause.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/pause/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PAUSE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/sound/list/list.html",'\n\n\n\n
\n

{{ \'APPLICATION_SOUNDS\' | translate }}

\n
\n
\n
\n
\n \n \n {{\'APPLICATION_FILE_UPLOAD\' | translate}} \n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_SELECT_FILES\' | translate}}\n \n
\n
\n
\n
\n
\n
\n
\n Base drop zone\n
\n
\n \n \n {{\'APPLICATION_FILE_UPLOAD\' | translate}}\n \n \n \n \n {{\'APPLICATION_MULTI_FILE_UPLOAD\' | translate}}\n
\n
\n

\n
\n {{ \'MESSAGE_SUPPORTED_FORMATS\' | translate }} wav, mp3, gsm, ogg.\n

\n

\n {{ \'MESSAGE_MAXIMUM_SOUND_UPLOAD_SIZE\' | translate }} 15 Mb.\n

\n
\n
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_UPLOAD_QUEUE\' | translate}}\n {{\'APPLICATION_QUEUE_LENGTH\' | translate}}: {{ uploader.queue.length }}\n
\n
\n
\n
\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_SIZE\' | translate}}{{\'APPLICATION_PROGRESS\' | translate}}{{\'APPLICATION_STATUS\' | translate}}{{\'APPLICATION_MESSAGE\' | translate}}{{\'APPLICATION_ACTIONS\' | translate}}
{{ item.file.name }}{{ item.file.size/1024/1024|number:2 }} MB\n
\n
\n
\n
\n \n \n \n \n \n {{item.responseMessage}}\n \n \n \n \n
\n
\n
\n

{{\'APPLICATION_UPLOAD_QUEUE_PROGRESS\' | translate}}:

\n
\n
\n
\n
\n \n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n

{{ \'MESSAGE_NO_SOUNDS\' | translate }}

\n

\n \n {{ \'MESSAGE_RETURN_HOME\' | translate }} \n {{ \'MESSAGE_OR_UPLOAD_SOUND_FILE\' | translate }}\n

\n
\n
\n
\n
\n
\n \n \n
\n
\n \n
\n

\n {{ sound.description || "Empty" }}\n

\n

\n \n \n \n

\n
\n
\n
\n \n
\n\n'), +a.put("app/tools/tag/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/tag/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TAGS\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/tag/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{tag.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/tag/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_TAG\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/template/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_TEMPLATES\' | translate }}\n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/template/view/view.html",'\n
\n
\n \n\n \n
\n\n \n
\n \n
\n \n
\n \n \n
\n
\n {{item.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/template/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n
\n
\n\n
\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n
\n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n\n
\n
\n
\n
\n {{\'APPLICATION_VARIABLES\' | translate}}\n
\n
\n
\n \n \n {{group.content | translate}}\n
    \n
  1. \n {{variable}}\n
  2. \n
\n
\n
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n\n \n
\n
\n
\n
\n
\n'),a.put("app/tools/template/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TEMPLATES\' | translate }} FORM \n
\n
\n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n
\n {{\'APPLICATION_VARIABLES\' | translate}}\n
\n
\n
\n \n \n {{group.content | translate}}\n
    \n
  1. \n {{variable}}\n
  2. \n
\n
\n
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n\n
\n \n
\n
\n
\n \n
\n'),a.put("app/tools/trigger/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_TRIGGERS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/trigger/view/view.html",'\n
\n
\n \n\n\n\n\n \n
\n \n
\n \n
\n \n
\n \n\n \n
\n
\n {{ trigger.name }}\n
\n
\n {{ trigger.description }}\n
\n
\n \n\n \n \n \n
\n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/trigger/view/view.settings.html",'
\n
\n
\n \n
\n \n
\n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ACTIONS\' | translate }}:\n
\n
\n
\n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n
\n \n
\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_CONDITION\' | translate}}.\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_ACTION\' | translate}}.\n \n
\n \n
\n
\n
\n
\n
\n
\n
\n'), +a.put("app/tools/trigger/wizard/wizard.html",'
\n
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TRIGGERS\' | translate }} WIZARD\n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n \n {{ \'APPLICATION_CHANNEL\' | translate }}\n
\n
\n
\n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ACTIONS\' | translate }}:\n
\n
\n
\n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n
\n \n
\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_CONDITION\' | translate}}.\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_ACTION\' | translate}}.\n \n
\n \n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/tools/trunk/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TRUNKS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/trunk/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{trunk.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/trunk/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_TRUNK\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_HOST\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_SECRET\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \' placeholder="{{\'APPLICATION_CALLERID\' | translate}}" class="form-control" data-ng-model="trunk.callerid"/>\n \n {{ \'DESCRIPTION_OUTBOUND_CALLERID\' | translate }} "name" <number>\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_TYPE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_DTMFMODE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_DEFAULT_USER\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_NAT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_QUALIFY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_ALLOW_CODEC\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_INSECURE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_CALLLIMIT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n \n \n
\n \n\n \n
\n
\n \n \n
\n
\n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_REGISTRY\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_DIRECTMEDIA\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_CALLCOUNTER\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_FROMDOMAIN\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_FROMUSER\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_OUTBOUNDPROXY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_USEREQPHONE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_TRUSTRPID\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_SENDRPID\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_ENCRYPTION\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_PORT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_TRANSPORT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n
\n \n \n
\n
\n
\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_OTHER_FIELDS\' | translate }}\n \n
\n \n
\n
\n
\n \n
\n
host=dynamicp
\n
secret=********
\n
regcontext=tammari-internal
\n
regexten=1005
\n
dtmfmode=rfc2833
\n
insecure=invite,port
\n
canreinvite=yes
\n
nat=yes
\n
qualify=yes
\n
context=merus-sipphone
\n
pickupgroup=1
\n
callgroup=1
\n
mailbox=1000@default
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n
\n'), +a.put("app/tools/trunk/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TRUNK\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_HOST\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_SECRET\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_DEFAULT_USER\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_REGISTRY\' | translate }}\n \n
\n \n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n'),a.put("app/tools/variable/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/variable/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_VARIABLES\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/variable/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{variable.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/variable/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_VARIABLE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/yourdashboard/list/clone.modal.html",'\n\n\n'),a.put("app/tools/yourdashboard/list/create.modal.html",'\n\n\n'),a.put("app/tools/yourdashboard/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_YOUR_DASHBOARDS\' | translate }} \n
\n
\n \n
\n \n
\n \n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/yourdashboard/show/show.html",'
\n
\n \n
\n
\n'),a.put("app/tools/yourdashboard/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{dashboard.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/yourdashboard/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_DASHBOARD\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/zendesk/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_ZENDESK\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/zendesk/view/configuration/list/create.modal.html",'\n\n\n'),a.put("app/zendesk/view/configuration/list/list.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n
\n
\n
\n
\n
\n'), +a.put("app/zendesk/view/configuration/view/view.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Select tags that you want add in the ticket:\n
\n
\n
\n
\n \n
\n \n {{$item.name}}\n \n {{tag.name}}\n \n \n
\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/zendesk/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/zendesk/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/zendesk/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_DOMAIN\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'), +a.put("components/footer/footer.html",'\n\n\n'),a.put("components/header/header.html",'\n\n\n'),a.put("components/modal/delete.html",'\n\n\n'),a.put("components/quickSidebar/modal/add.html",'\n\n\n\n\n'),a.put("components/quickSidebar/modal/close.html",'\n\n\n'),a.put("components/quickSidebar/quickSidebar.html",'
\n \n
\n'),a.put("components/sidebar/sidebar.html",'\n'); +}]); \ No newline at end of file diff --git a/public/app/32a97909.app.js b/public/app/32a97909.app.js deleted file mode 100644 index 999bc2b..0000000 --- a/public/app/32a97909.app.js +++ /dev/null @@ -1,51 +0,0 @@ -"use strict";angular.module("xCallyShuttleApp",["adf","adf.structures.base","adf.widget.clock","adf.widget.iframe","adf.widget.counter","adf.widget.pie-chart","angular-md5","angular.filter","angularFileUpload","btford.socket-io","chart.js","checklist-model","colorpicker.module","frapontillo.bootstrap-switch","infinite-scroll","LocalStorageModule","mgo-angular-wizard","ng-slide-down","ngAnimate","ngBootstrap","ngCookies","ngCsv","ngFileSaver","ngJsTree","ngMap","ngPapaParse","ngResource","ngSanitize","notification","oc.lazyLoad","pascalprecht.translate","pdf","remoteValidation","smart-table","sprintf","textAngular","timer","toastr","permission","ui-notification","ui.bootstrap.modal","ui.bootstrap.dropdown","ui.bootstrap.popover","ui.bootstrap.timepicker","ui.bootstrap.tooltip","ui.bootstrap.tpls","ui.bootstrap.accordion","ui.bootstrap.progressbar","ui.bootstrap.typeahead","ui.grid","ui.grid.autoResize","ui.grid.draggable-rows","ui.grid.exporter","ui.grid.grouping","ui.grid.moveColumns","ui.grid.pagination","ui.grid.treeView","ui.grid.selection","ui.grid.exporter","ui.grid.resizeColumns","ui.router","ui.navbar","ui.select","ui.sortable","xeditable","ngAudio","truncate","ngScrollbars","ngEmoticons","angularSpinner","builder","builder.components","validator","angular-clipboard","ng-code-mirror","angularMoment"]).config(["$stateProvider","$urlRouterProvider","$locationProvider","$httpProvider","$translateProvider","localStorageServiceProvider","dashboardProvider","ScrollBarsProvider",function(a,b,c,d,e,f,g,h){b.otherwise("/dashboard/voice"),e.useStaticFilesLoader({prefix:"assets/languages/locale-",suffix:".json"}),e.preferredLanguage("en_EN"),e.useLocalStorage(),e.useSanitizeValueStrategy("sanitize"),c.html5Mode(!0),d.interceptors.push("authInterceptor"),g.structure("4-4-4",{rows:[{columns:[{styleClass:"col-md-4"},{styleClass:"col-md-4"},{styleClass:"col-md-4"}]}]}).structure("3-3-3-3",{rows:[{columns:[{styleClass:"col-md-3"},{styleClass:"col-md-3"},{styleClass:"col-md-3"},{styleClass:"col-md-3"}]}]}),f.setPrefix("xcally"),h.defaults={scrollButtons:{scrollAmount:"auto",enable:!0},axis:"y"}}]).factory("settings",["$rootScope","$interval","License","localStorageService",function(a,b,c,d){return a.settings={patternName:"[A-Za-z0-9._]+",layout:{pageSidebarClosed:d.get("sidebarClosed")||!1,pageQuickSidebarOpened:!1,pageBodySolid:!1,pageAutoScrollOnLoad:1e3}},c.get(function(b){b.license&&(a.license=b.license,a.soundPath=b.soundPath)}),a.settings}]).factory("authInterceptor",["$rootScope","$q","$cookieStore",function(a,b,c){return{request:function(a){return a.headers=a.headers||{},c.get("token")&&(a.headers.Authorization="Bearer "+c.get("token")),a}}}]).run(["$rootScope","$location","$state","$stateParams","$window","$q","$http","Auth","RoleStore","editableThemes","editableOptions",function(a,b,c,d,e,f,g,h,i,j,k){g.get("/api/settings/1").success(function(b){a.license=b.license}).error(function(a){console.error(a)}),a.$state=c,a.$stateParams=d,j.bs3.inputClass="input-sm",j.bs3.buttonsClass="btn-xs",k.theme="bs3",a.online=navigator.onLine,e.addEventListener("offline",function(){a.$apply(function(){a.online=!1})},!1),e.addEventListener("online",function(){a.$apply(function(){a.online=!0})},!1),a.$on("$stateChangeStart",function(a,c){h.isLoggedInAsync(function(a){c.authenticate&&!a&&b.path("/login")})}),a.updateTableConfig=function(a,b){var c=_.find(a,{name:"All"});c&&(c.value=b)},i.defineRole("admin",[],function(){return h.isAdmin()})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics",{url:"/analytics",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("Extracted",["$resource",function(a){return a("/api/analytics/extracted/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.extracted",{url:"/extracted",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AnalyticExtractedListCtrl",["$scope","$translate","gridOptions","Extracted",function(a,b,c,d){a.moment=moment,a.Extracted=d,a.initView=function(){var b={exporterCsvFilename:"ExtractedReports.csv",columnDefs:[{name:"name"},{name:"startDate",displayName:"APPLICATION_START_DATE"},{name:"endDate",displayName:"APPLICATION_END_DATE"},{name:"createdAt",displayName:"APPLICATION_RUN_DATE"},{name:"startDate",displayName:"APPLICATION_START_DATE"},{name:"output"},{name:"status"},{name:"action",width:140,buttons:[{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"},{directive:""}]}]};a.gridOptions=c.gridOptions(d,b,a,{order:"createdAt DESC"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.extracted.list",{url:"/list",templateUrl:"app/analytic/extracted/list/list.html",controller:"AnalyticExtractedListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("AnalyticMetricListCreateModalCtrl",["$scope","$uibModalInstance",function(a,b){a.forms={dashboard:void 0},a.item={},a.tables=[{name:"Agent Report",value:"report_agent_history"},{name:"Mail Report",value:"report_mail_session_history"},{name:"Queue Report",value:"report_queue_history"},{name:"Integration Report",value:"report_integration_history"},{name:"Chat Report",value:"report_chat_session_history"}],a.ok=function(){a.item.model=JSON.stringify({title:a.item.name}),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("AnalyticMetricListCtrl",["$scope","xAlert","Modal","$uibModal","$log","gridOptions","Metric","$translate",function(a,b,c,d,e,f,g,h){a.$translate=h,a.initView=function(){var b={exporterCsvFilename:"Metrics.csv",columnDefs:[{name:"name"},{name:"table",cellTemplate:"
{{'APPLICATION_'+row.entity.table.toUpperCase() | translate}}
"},{name:"description"},{name:"action",width:125,buttons:[{"class":"{{row.entity.defaultEntry ? 'blue-hoki disabled' : 'blue-hoki'}}",href:"/analytics/metrics/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=f.gridOptions(g,b,a)},a.create=function(){var c=d.open({animation:!0,templateUrl:"app/analytic/metric/list/create.modal.html",controller:"AnalyticMetricListCreateModalCtrl"});c.result.then(function(c){return g.save(c).$promise.then(function(){a.gridOptions.getPage(),b.show(h.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(a.data.message,"danger")})},function(){e.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.metrics.list",{url:"/list",templateUrl:"app/analytic/metric/list/list.html",controller:"AnalyticMetricListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Metric",["$resource",function(a){return a("/api/analytics/metrics/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.metrics",{url:"/metrics",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AnalyticMetricViewCtrl",["$scope","xAlert","$translate","$stateParams","$location","Metric",function(a,b,c,d,e,f){a.tables=[{name:"Agent Report",value:"report_agent_history"},{name:"Mail Report",value:"report_mail_session_history"},{name:"Queue Report",value:"report_queue_history"},{name:"Integration Report",value:"report_integration_history"},{name:"Chat Report",value:"report_chat_session_history"}],a.getMetric=function(){return f.get({id:d.id}).$promise.then(function(b){a.metric=b})["catch"](function(a){e.path("/analytics/metrics/list")})},a.updateMetric=function(){return f.update({id:d.id},a.metric).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.metrics.view",{url:"/view/:id",templateUrl:"app/analytic/metric/view/view.html",controller:"AnalyticMetricViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.analytics.metrics.view.settings",{url:"/settings",templateUrl:"app/analytic/metric/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("customReport",["$resource",function(a){return a("/api/analytics/reports/custom/:id/:controller/:action",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("defaultReport",["$resource",function(a){return a("/api/analytics/reports/default/:id/:controller/:action",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("ReportListCopyModalCtrl",["$scope","$uibModalInstance","$log","customTreeData",function(a,b,c,d){a.customTreeData=d,a.forms={dashboard:void 0},a.item={},a.customTreeConfig={multiple:!1,animation:!0,core:{error:function(a){c.error("treeCtrl: error from js tree - "+angular.toJson(a))},check_callback:!0}},a.ac=function(){return!0},a.initCustomScopeTree=function(){a.customTree=a.customTreeInstance.jstree(!0),a.customTree.deselect_all(),a.customTree.open_all()},a.ok=function(){b.close({parent:a.customTree.get_selected(!0).pop().id})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ReportListCreateModalCtrl",["$scope","$uibModalInstance","path",function(a,b,c){a.path=c,a.forms={dashboard:void 0},a.item={},a.ok=function(){a.item.model=JSON.stringify({title:a.item.name}),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ReportListExtractModalCtrl",["$scope","$uibModalInstance",function(a,b){a.dates={startDate:moment().subtract(1,"days").startOf("day"),endDate:moment().subtract(1,"days").endOf("day")},a.ranges={Yesterday:[moment().subtract(1,"days").startOf("day"),moment().subtract(1,"days").endOf("day")],"Last 7 days":[moment().subtract(7,"days"),moment()],"Last 30 days":[moment().subtract(30,"days"),moment()],"This month":[moment().startOf("month"),moment().endOf("month")]},a.extract=function(c){var d={startDate:a.dates.startDate.toISOString(),endDate:a.dates.endDate.toISOString(),output:c};b.close(d)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("AnalyticReportListCtrl",["$scope","xAlert","$translate","$location","$log","Modal","$uibModal","FileSaver","Blob","gridOptions","customReport","defaultReport","reportTree",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){var b,c={},d=a.defaultTree.get_selected(),e=a.customTree.get_selected();if(d.length)b=d.pop(),a.selectedNode=a.defaultTree.get_path(b," / "),c={parent:b},a.gridOptions=j.gridOptions(l,o,a,c,!0),a.gridOptions.getPage();else{if(!e.length)return;b=e.pop(),a.selectedNode=a.customTree.get_path(b," / "),c={parent:b},a.gridOptions=j.gridOptions(k,o,a,c,!0),a.gridOptions.getPage()}}var o={exporterCsvFilename:"reports.csv",columnDefs:[{name:"name"},{name:"description"},{name:"manage",width:120,buttons:[{"class":"blue-hoki",href:"/analytics/reports/view/{{row.entity.id}}/settings",icon:"icon-settings",title:c.instant("APPLICATION_SETTINGS")},{"class":"red-sunglo",icon:"fa fa-trash-o",title:c.instant("APPLICATION_DELETE"),onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"},{"class":"green",icon:"fa fa-files-o",title:c.instant("APPLICATION_COPY"),onClick:"grid.appScope.copy(row.entity.id)"},{"class":"purple",icon:"fa fa-download",title:c.instant("APPLICATION_EXPORT"),onClick:"grid.appScope.export(row.entity.id)"}]},{name:"actions",buttons:[{"class":"yellow",name:"preview",onClick:"grid.appScope.preview(row.entity.id)"},{"class":"green-turquoise",name:"run",onClick:"grid.appScope.extract(row.entity.id)"}]}]};a.searchField="",a.ac=function(){return!0},a.initDefaultScopeTree=function(){a.defaultTree=a.defaultTreeInstance.jstree(!0),a.defaultTree.deselect_all(),a.defaultTree.close_all(),a.defaultTree.open_node({id:1}),a.defaultTreeReady=!0,a.defaultTreeActive=!0,a.previousDefaultNode=""},a.initCustomScopeTree=function(){a.customTree=a.customTreeInstance.jstree(!0),a.customTree.deselect_all(),a.customTree.close_all(),a.customTree.open_node({id:1}),a.customTreeReady=!0,a.previousCustomNode=""},a.$watchGroup(["defaultTreeReady","customTreeReady"],function(b,c,d){b[0]&&b[1]&&a.defaultTree.select_node({id:"1"})}),a.updateCustomTree=function(){var d={tree:angular.toJson(a.customTree.get_json("#",{flat:!0}))};return m.update({id:2},d).$promise.then(function(a){console.log("Custom Tree Updated")})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.configTrees=function(){a.defaultTreeConfig={multiple:!1,animation:!0,core:{error:function(a){e.error("treeCtrl: error from js tree - "+angular.toJson(a))},check_callback:!0,themes:{name:"default",url:"../../../assets/css/jstree-metronic/style.css"}},plugins:["search"]},a.customTreeConfig={multiple:!1,animation:!0,core:{error:function(a){e.error("treeCtrl: error from js tree - "+angular.toJson(a))},check_callback:!0,themes:{name:"default",url:"../../../assets/css/jstree-metronic/style.css"}},plugins:["contextmenu","dnd","search"],contextmenu:{items:function(b,d){var e={create:{label:c.instant("APPLICATION_CREATE"),action:function(c){a.customTree.create_node(b),a.customTree.open_node(b)}},rename:{label:c.instant("APPLICATION_RENAME"),action:function(c){a.customTree.edit(b)}},remove:{label:c.instant("APPLICATION_REMOVE"),action:function(c){console.log(b),a.deleteNode(b.text,b)}}};return"#"===b.parent&&(delete e.rename,delete e.remove),d(e),e}}}},a.deleteNode=f.confirm["delete"](function(b){a.customTree.delete_node(b),a.previousCustomNode==b.id&&a.customTree.select_node({id:b.parent})}),a.searchTrees=function(){a.defaultTree.search(a.searchField),a.customTree.search(a.searchField)},a.selectDefaultNode=function(){if(a.customTreeReady){a.previousCustomNode="";var b=a.defaultTree.get_selected(!0),c=b.pop();if(a.defaultTree.deselect_node(b[0],!0),a.customTree.deselect_all(),a.defaultTree.select_node(c,!0),c.id===a.previousDefaultNode)return void console.log("def");a.previousDefaultNode=c.id,a.defaultTreeActive=!0,n()}},a.selectCustomNode=function(){if(a.defaultTreeReady){a.previousDefaultNode="";var b=a.customTree.get_selected(!0),c=b.pop();if(a.customTree.deselect_node(b[0],!0),a.defaultTree.deselect_all(),a.customTree.select_node(c,!0),c.id===a.previousCustomNode)return void console.log("cus");a.previousCustomNode=c.id,a.defaultTreeActive=!1,n()}},a.getTrees=function(){return m.query().$promise.then(function(b){a.defaultTreeData=JSON.parse(b[0].tree),a.customTreeData=JSON.parse(b[1].tree),a.configTrees()})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.create=function(){var c=g.open({animation:!0,templateUrl:"app/analytic/report/list/create.modal.html",controller:"ReportListCreateModalCtrl",resolve:{path:function(){return a.selectedNode}}});c.result.then(function(c){return c.parent=a.previousCustomNode,k.save(c).$promise.then(function(a){d.path("/analytics/reports/view/"+a.id+"/settings")})["catch"](function(a){b.show(a.message,"danger")})},function(){e.info("Modal dismissed at: "+new Date)})},a.copy=function(d){var f=a.defaultTreeActive?l:k,h=g.open({animation:!0,templateUrl:"app/analytic/report/list/copy.modal.html",controller:"ReportListCopyModalCtrl",resolve:{customTreeData:function(){return a.customTreeData}}});h.result.then(function(e){return f.save({id:d,controller:"copy"},e).$promise.then(function(){a.gridOptions.getPage(),b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message,"danger")})},function(){e.info("Modal dismissed at: "+new Date)})},a["export"]=function(c){var d=a.defaultTreeActive?l:k;return d.get({id:c}).$promise.then(function(a){delete a.id,delete a.createdAt,delete a.updatedAt,delete a.deletedAt,_.forEach(a.Fields,function(a){delete a.id,delete a.CustomReportId,a.Metric&&(delete a.Metric.id,a.Metric.name+="_"+_.random(9999))});var b=new i([angular.toJson(a)],{type:"application/json;charset=utf-8"});h.saveAs(b,a.name+".json")})["catch"](function(a){console.error(data),b.show(a.message,"danger")})},a["import"]=function(d){var e=JSON.parse(d);e.parent=a.previousCustomNode;var f=e.name&&e.parent?!0:!1,g=!0;return _.forEach(e.Fields,function(a){a.field&&a.alias||(g=!1)}),f&&g?k.save({controller:"import"},e).$promise.then(function(){a.gridOptions.getPage(),b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message,"danger")}):void b.show(c.instant("MESSAGE_INVALID_JSON"),"danger")},a.preview=function(b){g.open({animation:!0,templateUrl:"app/analytic/report/list/preview.modal.html",controller:"ReportListPreviewModalCtrl",size:"full",resolve:{report:function(){return{id:b,tree:a.defaultTreeActive?"default":"custom"}}}})},a.extract=function(d){var f=g.open({animation:!0,templateUrl:"app/analytic/report/list/extract.modal.html",controller:"ReportListExtractModalCtrl",size:"md",resolve:{report:function(){return{id:d,tree:a.defaultTreeActive?"default":"custom"}}}});f.result.then(function(e){var f=a.defaultTreeActive?l:k;return f.get({id:d,controller:"extract",action:e.output,startDate:e.startDate,endDate:e.endDate}).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message,"danger")})},function(){e.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.reports.list",{url:"/list",templateUrl:"app/analytic/report/list/list.html",controller:"AnalyticReportListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ReportListPreviewModalCtrl",["$scope","$uibModalInstance","report","xAlert","$translate","$timeout","customReport","defaultReport",function(a,b,c,d,e,f,g,h){a.forms={dashboard:void 0},a.dates={startDate:moment().subtract(1,"days").startOf("day"),endDate:moment().subtract(1,"days").endOf("day")},a.ranges={Yesterday:[moment().subtract(1,"days").startOf("day"),moment().subtract(1,"days").endOf("day")],"Last 7 days":[moment().subtract(7,"days"),moment()],"Last 30 days":[moment().subtract(30,"days"),moment()],"This month":[moment().startOf("month"),moment().endOf("month")]};var i={pageNumber:1,pageSize:25,sort:null,where:{},order:{}};a.gridOptions={paginationPageSizes:[10,25,50],paginationPageSize:25,useExternalPagination:!0,enableSorting:!1,enableFiltering:!0,useExternalFiltering:!0,enableGrouping:!1,enableColumnMenus:!1,treeRowHeaderAlwaysVisible:!1,gridMenuShowHideColumns:!1,enableGridMenu:!1,onRegisterApi:function(b){a.gridApi=b,b.pagination.on.paginationChanged(a,function(b,c){i.offset=(b-1)*c,i.limit=c,a.getPage()}),b.core.on.filterChanged(a,function(){var b=this.grid,c={};b.columns.forEach(function(a){console.log(a),a.filters[0].term&&(c[a.field]=a.filters[0].term)}),i.where=c,a.getPage()})}},a.getPage=function(){var b={params:{offset:i.offset,limit:i.limit,startDate:a.dates.startDate.toISOString(),endDate:a.dates.endDate.toISOString()}};_.forOwn(i.where,function(a,c){b.params[c]=a}),console.log(b);var f="custom"===c.tree?g:h;return f.get({id:c.id,controller:"preview"},b).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.paginationPageSizes[3]=b.count,a.gridOptions.data=b.rows,a.showResult=!0})["catch"](function(a){d.show(e.instant(a.message),"danger")})},a.cancel=function(){b.dismiss("cancel")},f(function(){a.getPage()})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.reports",{url:"/reports",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("reportTree",["$resource",function(a){return a("/api/analytics/reports/trees/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("AnalyticReportViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location",function(a,b,c,d,e,f){function g(e){var f=_.find(a.tables,{table:e}).url;b.get(f).success(function(b){a.tableFields=_.map(b,function(a,b){return{name:b,value:b}})}).error(function(a){c.show(d.instant(a.message),"danger")})}function h(e){console.log(e),b.get("/api/analytics/metrics/table",{params:{table:e}}).success(function(b){_.forEach(b,function(b){a.tableFields.push({name:"Metric."+b.name,value:b.metric,MetricId:b.id})})}).error(function(a){c.show(d.instant(a.message),"danger")})}function i(a){return String(a).replace(//g,">")}function j(a){if(!a)return"";for(var b="(",c=0;c0&&(b+=" "+a.operator+" "),b+=a.rules[c].group?j(a.rules[c].group):a.rules[c].field+" "+i(a.rules[c].condition)+" '"+("like"===a.rules[c].condition?"%"+a.rules[c].value+"%":a.rules[c].value)+"'";return b+")"}a.$translate=d,a.tempReport={},a.tables=[{name:"Agent Report",table:"report_agent_history",url:"/api/report/agents/describe"},{name:"Mail Report",table:"report_mail_session_history",url:"/api/report/mail/sessions/describe"},{name:"Queue Report",table:"report_queue_history",url:"/api/report/queues/describe"},{name:"Chat Report",table:"report_chat_session_history",url:"/api/report/chat/sessions/describe"}];var k={group:{operator:"AND",rules:[]}};a.getReport=function(){a.firstLoad=!0,b.get("/api/analytics/reports/custom/"+e.id).success(function(b){a.report=b,_.forEach(a.report.Fields,function(a){delete a.id}),a.report.conditions=a.report.conditions?JSON.parse(a.report.conditions):_.clone(k,!0),a.getPreview(a.report.Fields.length)}).error(function(a){console.error(a),f.path("/analytics/reports/list")})},a.randomName=function(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")},a.$watch("report.table",function(b,c){console.log(b),b&&(console.log("is newvalue"),g(b),h(b),c&&(console.log("is oldvalue"),a.tempReport[c]={conditions:a.report.conditions,fields:a.report.Fields}),a.firstLoad?a.firstLoad=!1:a.tempReport[b]?(a.report.Fields=a.tempReport[b].fields,a.report.conditions=a.tempReport[b].conditions):(a.report.Fields=[],a.report.conditions=_.clone(k,!0)))},!0),a.setMetricId=function(b,c){a.report.Fields[c].MetricId=b.MetricId?b.MetricId:null},a.groupByField=[{name:"APPLICATION_YES",value:!0},{name:"APPLICATION_NO",value:!1}],a.functions=[{name:"Sum",value:"SUM"},{name:"Count",value:"COUNT"},{name:"Count Distinct",value:"COUNT DISTINCT"},{name:"Maximum",value:"MAX"},{name:"Minimum",value:"MIN"},{name:"Average",value:"AVG"},{name:"Group Concat",value:"GROUP_CONCAT"},{name:"Group Concat(asc)",value:"GROUP_CONCAT ASC"},{name:"Group Concat(desc)",value:"GROUP_CONCAT DESC"}],a.addField=function(){a.report.Fields.push({groupBy:!1})},a.removeField=function(b){a.report.Fields.splice(b,1)},a.sortableOptions={"ui-floating":!0,cancel:".unsortable",handle:".report-field-handle",axis:"y"},a.updateReport=function(){if(a.report.Fields.length){var f=angular.copy(a.report);f.conditions=angular.toJson(f.conditions),b.put("/api/analytics/reports/custom/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success"),a.getPreview(!0)}).error(function(b){c.show(d.instant(b.message),"danger"),f.conditions=JSON.parse(f.conditions),a.report=f})}else c.show(d.instant("MESSAGE_SELECT_A_FIELD"),"danger")},a.$watch("report.conditions",function(b){a.output=b?j(b.group):"()"},!0),a.gridOptions={enableFiltering:!0,treeRowHeaderAlwaysVisible:!1,enableGridMenu:!0},a.getPreview=function(f){b.get("/api/analytics/reports/custom/"+e.id+"/preview/",{params:{limit:20}}).success(function(b){a.gridOptions.data=b.rows}).error(function(a){f&&c.show(d.instant(a.message||"MESSAGE_QUERY_NOT_VALID"),"warning")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.analytics.reports.view",{url:"/view/:id",templateUrl:"app/analytic/report/view/view.html",controller:"AnalyticReportViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.analytics.reports.view.settings",{url:"/settings",templateUrl:"app/analytic/report/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels",{url:"/channels",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat",{url:"/chat",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("ChatEnquiry",["$resource",function(a){return a("/api/chat/enquiries/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatMessage",["$resource",function(a){return a("/api/chat/messages/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatReport",["$resource",function(a){return a("/api/report/chats/:id/:controller1/:controller2",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatRoom",["$resource",function(a){return a("/api/chat/rooms/:id/:controller",{id:"@id"},{me:{method:"GET",isArray:!0,params:{id:"me"}},users:{method:"GET",params:{id:"users"}},externals:{method:"GET",isArray:!0,params:{id:"type",controller:"external"}},groups:{method:"GET",isArray:!0,params:{id:"groups"}},update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatVisitor",["$resource",function(a){return a("/api/chat/visitors/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("ChatOfflineListCtrl",["$scope","ChatVisitor","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"chat_offline_messages.csv",columnDefs:[{name:"fullname",cellClass:"text-center"},{name:"email",cellClass:"text-center"},{name:"ChatWebsite.name",displayName:"Website",cellClass:"text-center"},{name:"createdAt",displayName:"createdAt",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'},{name:"action",width:100,buttons:[{"class":"blue-hoki",href:"/channels/chat/offline/view/{{row.entity.id}}/detail",name:"detail"}]}]};a.gridOptions=c.gridOptions(b,d,a,{origin:"enquiry"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.offline.list",{url:"/list",templateUrl:"app/channels/chat/offline/list/list.html",controller:"ChatOfflineListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.offline",{url:"/offline",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatOfflineViewCtrl",["$scope","$stateParams","ChatVisitor",function(a,b,c){a.initView=function(){return c.get({id:b.id}).$promise.then(function(b){a.chatVisitor=b})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.offline.view",{url:"/view/:id",templateUrl:"app/channels/chat/offline/view/view.html",controller:"ChatOfflineViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.chat.offline.view.detail",{url:"/detail",templateUrl:"app/channels/chat/offline/view/view.detail.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/news.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("ChatOnlineListCtrl",["$scope","ChatRoom","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"chat_online_messages.csv",columnDefs:[{name:"ChatVisitor.fullname",displayName:"APPLICATION_FULLNAME",cellClass:"text-center"},{name:"ChatVisitor.email",displayName:"APPLICATION_EMAIL",cellClass:"text-center"},{name:"action",width:100,buttons:[{"class":"blue-hoki",href:"/channels/chat/online/view/{{row.entity.id}}/detail",name:"detail"}]}]};a.gridOptions=c.gridOptions(b,d,a,{type:"external"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.online.list",{url:"/list",templateUrl:"app/channels/chat/online/list/list.html",controller:"ChatOnlineListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.online",{url:"/online",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatOnlineViewCtrl",["$scope","$stateParams","ChatRoom",function(a,b,c){a.initView=function(){return a.config={autoHideScrollbar:!1,theme:"light",advanced:{updateOnContentResize:!0},setHeight:400,scrollInertia:0},c.get({id:b.id}).$promise.then(function(b){a.chatRoom=b})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.online.view",{url:"/view/:id",templateUrl:"app/channels/chat/online/view/view.html",controller:"ChatOnlineViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.chat.online.view.detail",{url:"/detail",templateUrl:"app/channels/chat/online/view/view.detail.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/news.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("PreviewCtrl",["$scope",function(a){a.message="Hello"}]),angular.module("xCallyShuttleApp").directive("preview",function(){return{templateUrl:"app/channels/chat/preview/preview.html",restrict:"EA",link:function(a,b,c){}}}),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("preview",{url:"/preview",templateUrl:"app/channels/chat/preview/preview.html",controller:"PreviewCtrl"})}]),angular.module("xCallyShuttleApp").factory("ChatQueue",["$resource",function(a){return a("/api/chat/queues/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("ChatQueueListCtrl",["$scope","ChatQueue","gridOptions","$uibModal",function(a,b,c,d){a.initView=function(){var d={exporterCsvFilename:"chat_queues.csv",columnDefs:[{name:"name"},{name:"description"},{name:"strategy"},{name:"timeout"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/chat/queues/view/{{row.entity.id}}/settings", -name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){var b=d.open({animation:!0,templateUrl:"app/channels/mail/queue/list/list.create.modal.html",controller:"ChatQueueListCreateCtrl"});b.result.then(function(){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("ChatQueueListCreateCtrl",["$scope","$uibModalInstance","$translate","xAlert","ChatQueue",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return e.save(a.item).$promise.then(function(a){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),b.close(a)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.queues.list",{url:"/list",templateUrl:"app/channels/chat/queue/list/list.html",controller:"ChatQueueListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.queues",{url:"/queues",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatQueueViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","ChatQueue","Team",function(a,b,c,d,e,f,g){var h=function(){return{select:function(b){return f.save({id:a.queue.id,controller:"agents"},{agents:b,penalty:a.queue.penalty}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})},deselect:function(b){return f["delete"]({id:a.queue.id,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})}}};a.getQueue=function(){b.get("/api/chat/queues/"+e.id).success(function(b){b.penalty=0,a.queue=b}).error(function(a){console.error(a)})},a.updateChatQueue=function(){var f=angular.copy(a.queue);b.put("/api/chat/queues/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(b){a.queue=f,b.errors.forEach(function(a){c.show(a.message,"danger")})})},a.getTeams=function(){return g.get().$promise.then(function(b){return a.teams=b.rows,f.query({id:e.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindChatQueue(a.teams,_.map(b,function(a){return{id:a.id,penalty:a.UserHasChatQueue.penalty}}),h)})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.queues.view",{url:"/view/:id",templateUrl:"app/channels/chat/queue/view/view.html",controller:"ChatQueueViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.chat.queues.view.settings",{url:"/settings",templateUrl:"app/channels/chat/queue/view/view.settings.html"}).state("main.channels.chat.queues.view.agents",{url:"/agents",templateUrl:"app/channels/chat/queue/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.realtime",{url:"/realtime",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewAgentCtrl",["$scope","$log","$uibModal","$translate","socket","xAlert","Agent","Pause","Action","ChatQueue","usSpinnerService","$q","uiGridConstants",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){return k.spin("spinner-grid"),g.get(s).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.data=[],b.rows.forEach(function(a){p(a)})})["catch"](function(a){f.show(a.message,"danger")})["finally"](function(){k.stop("spinner-grid")})}function o(){e.socket.on("agent:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.id,isAgent:!0});if(c){var d=a.gridOptions.data.indexOf(c);a.gridOptions.data[d].online=b.online,a.gridOptions.data[d].lastLoginAt=b.lastLoginAt,a.gridOptions.data[d].pause=b.chatPause,a.gridOptions.data[d].pauseType=b.pauseType,a.gridOptions.data[d].lastPauseAt=b.lastPauseAt,a.gridOptions.data[d].ipaddr=b.ipaddr,a.gridOptions.data[d].port=b.port,a.gridOptions.data[d].fullcontact=b.fullcontact,a.gridOptions.data[d].useragent=b.useragent,a.gridOptions.data[d].lastms=b.lastms,a.gridOptions.data[d].internal=b.internal,_.map(a.gridOptions.data,function(a){a.isAgent||a.agentId!==b.id||(a.online=b.online)})}}),e.socket.on("agent:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.id})}),e.socket.on("user_has_chat_queue:save",function(b){console.log("new queue",b);var c=_.find(a.gridOptions.data,{agentId:b.UserId,isAgent:!0}),d=a.gridOptions.data.indexOf(c);a.gridOptions.data.splice(d+1,0,{isAgent:!1,agentId:b.UserId,queue:b.queue,queueId:b.ChatQueueId,agent:b.membername,online:c.online})}),e.socket.on("user_has_chat_queue:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.UserId,queueId:b.ChatQueueId})})}function p(b){a.gridOptions.data.push({isAgent:!0,agentId:b.id,agent:b.name,online:b.online,lastLoginAt:b.lastLoginAt,lastPauseAt:b.lastPauseAt,pause:b.chatPause,pauseType:b.pauseType,ipaddr:b.ipaddr,port:b.port,fullcontact:b.fullcontact,useragent:b.useragent,lastms:b.lastms,internal:b.internal,$$treeLevel:0}),b.ChatQueues.forEach(function(c){a.gridOptions.data.push({isAgent:!1,agentId:b.id,queue:c.name,queueId:c.id,agent:b.name,online:b.online})})}function q(){return h.get().$promise.then(function(b){a.pauses=b.rows,e.syncUpdates("pause",a.pauses)})["catch"](function(a){f.show(a.message,"danger")})}function r(){return j.get().$promise.then(function(b){a.chatQueues=b.rows,e.syncUpdates("chat_queue",a.chatQueues)})["catch"](function(a){f.show(a.message,"danger")})}a.chatQueues=[];var s={offset:0,limit:10};a.moment=moment,a.initAgents=function(){a.gridOptions={enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,showTreeExpandNoChildren:!0,columnDefs:[{name:"name",displayName:"APPLICATION_AGENT",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.agent}} <{{row.entity.internal}}>
'},{name:"online",displayName:"APPLICATION_ONLINE",width:150,headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
({{hhours}}:{{mminutes}}:{{sseconds}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"ONLINE"},{value:"false",label:"OFFLINE"}]}},{name:"chatPause",width:300,displayName:"APPLICATION_PAUSE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{hhours}}:{{mminutes}}:{{sseconds}}({{row.entity.pauseType}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"PAUSED"},{value:"false",label:"NOT PAUSED"}]},enableSorting:!1,enableColumnMenu:!1},{name:"queue",displayName:"APPLICATION_QUEUE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",displayName:"",width:170,cellClass:"text-center ui-grid-vcenter",cellTemplate:'
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1}],data:[],gridMenuTitleFilter:function(a){var b=l.defer();return b.resolve(d.instant(a)),b.promise},onRegisterApi:function(b){a.gridApi=b,a.gridApi.grid.registerDataChangeCallback(function(){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length)}),a.gridApi.treeBase.on.rowExpanded(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length+b.treeNode.children.length)}),a.gridApi.treeBase.on.rowCollapsed(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length-b.treeNode.children.length)}),a.gridApi.core.on.sortChanged(a,function(a,b){0===b.length?s.order=null:s.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),n()}),a.gridApi.pagination.on.paginationChanged(a,function(a,b){s.offset=(a-1)*b,s.limit=b,n()}),a.gridApi.core.on.filterChanged(a,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?s[a.name]=a.filters[0].term:delete s[a.name]}),n()})}},n(),q(),r(),o()};var t=function(a){var b=a?30*a+130:270;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px"),angular.element(document.getElementsByClassName("ui-grid-viewport")).css("height",30*a+"px")};a.$on("$destroy",function(){e.unsyncUpdates("agent"),e.unsyncUpdates("user_has_chat_queue")}),a.pause=function(a,b,c){return i.save({name:b,agent:a,type:c||"DEFAULT PAUSE",data4:c||"DEFAULT PAUSE",channel:"chat"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.joinQueue=function(e){var g=c.open({animation:!0,templateUrl:"app/channels/chat/realtime/view/agent/queue.modal.add.html",controller:"ChatRealtimeViewAgentQueueModalCtrl",resolve:{queues:function(){return _.reject(a.chatQueues,function(b){return _.find(a.gridOptions.data,{queue:b.name,isAgent:!1,agentId:e})?!0:!1})}}});g.result.then(function(b){return i.save({name:"QueueAdd",agent:e,queues:_.filter(a.chatQueues,function(a){return _.includes(b.queues,a.id)}),channel:"chat",data1:e,data3:b.queues.join(","),data4:"chat"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},function(){b.info("Modal dismissed at: "+new Date)})},a.leaveQueue=function(a,b){return i.save({name:"QueueRemove",agent:a,queueId:b,channel:"chat",data1:a,data3:b,data4:"chat"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.showInfo=function(a){c.open({animation:!0,templateUrl:"app/channels/chat/realtime/view/agent/agent.modal.info.html",controller:"ChatRealtimeViewAgentInfoModalCtrl",resolve:{agent:a}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.realtime.view.agents",{url:"/agents",templateUrl:"app/channels/chat/realtime/view/agent/agent.html",controller:"ChatRealtimeViewAgentCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewAgentInfoModalCtrl",["$scope","$uibModalInstance","$http","agent",function(a,b,c,d){a.agent=d,a.close=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewAgentQueueModalCtrl",["$scope","$uibModalInstance","$http","queues",function(a,b,c,d){a.queues=d,a.item={},a.save=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewQueueCtrl",["$scope","$http","socket","ChatQueue","Agent",function(a,b,c,d,e){a.initQueues=function(){a.gridOptions={enableSorting:!1,enableFiltering:!0,enableHorizontalScrollbar:0,enableVerticalScrollbar:0,showTreeExpandNoChildren:!1,columnDefs:[{name:"queueName",displayName:"Queue"},{name:"fullname",displayName:"Agent",cellClass:"text-center"},{name:"online",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'},{name:"chatPause",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
"},{name:"pauseType",cellClass:"text-center",cellTemplate:'{{row.entity.pauseType}}'},{name:"lastLoginAt",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'}],onRegisterApi:function(b){a.gridApi=b,a.gridApi.treeBase.on.rowExpanded(a,function(b){var c=_.findIndex(a.gridOptions.data,{$$hashKey:b.entity.$$hashKey});b.entity.Users&&b.entity.Users.forEach(function(b){_.find(a.gridOptions.data,{name:b.name})||a.gridOptions.data.splice(c+1,0,b)})})}},d.get(function(b){a.gridOptions.data=[],b.rows.forEach(function(b){b.$$treeLevel=0,b.queueName=b.name,a.gridOptions.data.push(b),b.Users&&b.Users.forEach(function(b){b.agentName=b.name,a.gridOptions.data.push(b)})}),c.socket.on("agent:save",function(b){var c=_.filter(a.gridOptions.data,{agentName:b.name});c.forEach(function(a){a.online=b.online,a.lastLoginAt=b.lastLoginAt})}),c.socket.on("chat_queue:save",function(b){b.$$treeLevel=0,b.queueName=b.name,a.gridOptions.data.push(b)}),c.socket.on("chat_queue:remove",function(b){_.remov(a.gridOptions.data,{queueName:b.name})}),c.socket.on("user_has_chat_queue:save",function(b){var c=_.findIndex(a.gridOptions.data,function(a){return a.queueName&&a.id===b.ChatQueueId});e.get({id:b.UserId}).$promise.then(function(b){a.gridOptions.data.splice(c+1,0,{id:b.id,name:b.name,fullname:b.fullname,agentName:b.name,online:b.online,lastLoginAt:b.lastLoginAt})})["catch"](function(a){console.error(a)})}),c.socket.on("user_has_chat_queue:remove",function(b){for(var c=_.findIndex(a.gridOptions.data,function(a){return a.queueName&&a.id===b.ChatQueueId}),d=c+1;dApril 1, 2014',sort:{direction:d.DESC,priority:1}},{name:"leaveAt",cellClass:"text-center",cellTemplate:''},{name:"unmanagedAt",cellClass:"text-center",cellTemplate:''}],data:[]},b.get("/api/report/chat/sessions").success(function(b){a.gridOptions.data=b.rows,c.socket.on("report_chat_session:save",function(b){var c=_.find(a.gridOptions.data,{id:b.id}),d=a.gridOptions.data.indexOf(c);c?_.merge(a.gridOptions.data[d],b):a.gridOptions.data.unshift(b)})}).error(function(a){console.error(a)})},a.$on("$destroy",function(){c.unsyncUpdates("report_chat:save"),c.unsyncUpdates("report_chat:update")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.realtime.view.sessions",{url:"/sessions",templateUrl:"app/channels/chat/realtime/view/session/session.html",controller:"ChatRealtimeViewSessionCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatRealtimeViewCtrl",["$scope",function(a){a.agents=[{name:"Queues",link:"main.chat.realtime.view.agent.queues"},{name:"Timeline",link:"main.chat.realtime.view.agent.timeline"}],a.sessions=[{name:"Sessions",link:"main.chat.realtime.view.sessions"}]}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.realtime.view",{url:"/view",templateUrl:"app/channels/chat/realtime/view/view.html",controller:"ChatRealtimeViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatVisitorListCtrl",["$scope","ChatVisitor","gridOptions","$uibModal",function(a,b,c,d){a.initView=function(){var d={exporterCsvFilename:"chat_visitors.csv",columnDefs:[{name:"fullname",cellClass:"text-center"},{name:"email",cellClass:"text-center"},{name:"origin",cellClass:"text-center"},{name:"createdAt",displayName:"createdAt",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'},{name:"action",width:100,buttons:[{"class":"blue-hoki",href:"/channels/chat/visitors/view/{{row.entity.id}}/profile",name:"profile"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.visitors.list",{url:"/list",templateUrl:"app/channels/chat/visitor/list/list.html",controller:"ChatVisitorListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatVisitorViewCtrl",["$scope","$stateParams","ChatVisitor",function(a,b,c){a.initView=function(){return c.get({id:b.id}).$promise.then(function(b){a.chatVisitor=b})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.visitors.view",{url:"/view/:id",templateUrl:"app/channels/chat/visitor/view/view.html",controller:"ChatVisitorViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.chat.visitors.view.profile",{url:"/profile",templateUrl:"app/channels/chat/visitor/view/view.profile.html"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.visitors",{url:"/visitors",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("ChatApplication",["$resource",function(a){return a("/api/chat/applications/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChatWebsite",["$resource",function(a){return a("/api/chat/websites/:websiteId/:controller/:id",{id:"@websiteId"},{update:{method:"PUT"},updateFields:{method:"PUT",isArray:!0}})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteListCtrl",["$scope","gridOptions","ChatWebsite",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"chat_websites.csv",columnDefs:[{name:"name"},{name:"description"},{name:"address"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/chat/websites/view/{{row.entity.id}}/embedding/view",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.list",{url:"/list",templateUrl:"app/channels/chat/website/list/list.html",controller:"ChatWebsiteListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.actions",{url:"/actions",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewActionListCtrl",["$scope","gridOptions","ChatWebsite","$http","$translate","$stateParams","socket","xAlert","Modal",function(a,b,c,d,e,f,g,h,i){a.initActons=function(){var d={draggable:!0,exporterCsvFilename:"chat_applications.csv",columnDefs:[{name:"app",cellClass:"text-center"},{name:"name",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.ChatQueue ? row.entity.ChatQueue.name : row.entity.User.name}}
"},{name:"timeout",cellClass:"text-center"},{name:"interval",cellClass:"text-center"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/chat/websites/view/{{row.entity.ChatWebsiteId}}/actions/view/{{row.entity.id}}",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.app, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a,{websiteId:f.websiteId,controller:"applications"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.actions.list",{url:"/list",templateUrl:"app/channels/chat/website/view/action/list/list.html",controller:"ChatWebsiteViewActionListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewActionViewCtrl",["$scope","$http","$stateParams","$translate","$location","xAlert","WizardHandler","socket","application","interval","ChatApplication","ChatQueue","Agent","Interval",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initAction=function(){return a.$application=i.application,a.$stateParams=c,a.$interval=j.interval,a.forms={},a.apps=[{name:"Queue",value:"queue"},{name:"Agent",value:"agent"}],k.get({id:c.actionId}).$promise.then(function(b){if(a.application=b,a.application.alwaysTime=!1,a.application.IntervalId)a.application.intType="list";else switch(a.application.interval){case"*,*,*,*":a.application.intType="always";break;default:a.application.intType="custom"}var c=a.application.interval.split(",");"*"===c[0]?a.application.alwaysTime=!0:(a.application.t_from=moment(new Date),a.application.t_to=moment(new Date),a.application.t_from.hour(c[0].split("-")[0].split(":")[0]),a.application.t_from.minute(c[0].split("-")[0].split(":")[1]),a.application.t_to.hour(c[0].split("-")[1].split(":")[0]),a.application.t_to.minute(c[0].split("-")[1].split(":")[1])),"*"===c[1]?(a.application.wd_from="always",a.application.wd_to="always"):(a.application.wd_from=c[1].split("-")[0],a.application.wd_to=c[1].split("-")[1]),"*"===c[2]?(a.application.md_from="always",a.application.md_to="always"):(a.application.md_from=c[2].split("-")[0],a.application.md_to=c[2].split("-")[1]),"*"===c[3]?(a.application.m_from="always",a.application.m_to="always"):(a.application.m_from=c[3].split("-")[0],a.application.m_to=c[3].split("-")[1]),a.$watch("application.t_from",function(b){a.application.t_from_hm=moment(b).format("HH:mm")}),a.$watch("application.t_to",function(b){a.application.t_to_hm=moment(b).format("HH:mm")})})["catch"](function(a){f.show(d.instant("Something went wrong!"),"danger")})},a.getQueues=function(){return l.get().$promise.then(function(b){a.queues=b.rows})["catch"](function(a){console.error(a)})},a.getAgents=function(){return m.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)})},a.getIntervals=function(){return n.get().$promise.then(function(b){a.intervals=b.rows})["catch"](function(a){console.error(a)})},a.updateItem=function(){var b=["*","*","*","*"],e={app:a.application.app,timeout:a.application.timeout,chatAccountId:c.id};switch(a.application.app){case"agent":e.UserId=a.application.UserId;break;case"queue":e.chatQueueId=a.application.chatQueueId}switch(a.application.intType){case"always":e.interval=b.join(","),delete a.application.IntervalId;break;case"custom":a.application.alwaysTime||(b[0]=a.application.alwaysTime?"*":a.application.t_from_hm+"-"+a.application.t_to_hm),a.application.wd_from&&a.application.wd_to&&"always"===a.application.wd_from&&"always"===a.application.wd_to?b[1]="*":b[1]=a.application.wd_from&&a.application.wd_to?a.application.wd_from+"-"+a.application.wd_to:"*",a.application.md_from&&a.application.md_to&&"always"===a.application.md_from&&"always"===a.application.md_to?b[2]="*":b[2]=a.application.md_from&&a.application.md_to?a.application.md_from+"-"+a.application.md_to:"*",a.application.m_from&&a.application.m_to&&"always"===a.application.m_from&&"always"===a.application.m_to?b[3]="*":b[3]=a.application.m_from&&a.application.m_to?a.application.m_from+"-"+a.application.m_to:"*",e.interval=b.join(","),delete a.application.IntervalId;break;case"list":e.IntervalId=a.application.IntervalId}return k.update({id:c.actionId},e).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.actions.view",{url:"/view/:actionId",templateUrl:"app/channels/chat/website/view/action/view/view.html",controller:"ChatWebsiteViewActionViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewActionWizardCtrl",["$scope","$http","Agent","Interval","ChatQueue","$stateParams","$translate","$location","xAlert","WizardHandler","socket","application","interval",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initWizard=function(){a.apps=[{name:"Queue",value:"queue"},{name:"Agent",value:"agent"}],a.$application=l.application,a.$stateParams=f,a.$interval=m.interval,a.forms={},a.application={app:"queue",intType:"always",alwaysTime:!0},a.$watch("application.t_from",function(b){a.application.t_from_hm=moment(b).format("HH:mm")}),a.$watch("application.t_to",function(b){a.application.t_to_hm=moment(b).format("HH:mm")})},a.getQueues=function(){return e.get().$promise.then(function(b){a.queues=b.rows})["catch"](function(a){console.error(a)})},a.getAgents=function(){return c.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)})},a.getIntervals=function(){return d.get().$promise.then(function(b){a.intervals=b.rows})["catch"](function(a){console.error(a)})},a.createItem=function(){var c=["*","*","*","*"],d={app:a.application.app,timeout:a.application.timeout,ChatWebsiteId:f.websiteId};switch(a.application.app){case"agent":d.UserId=a.application.UserId;break;case"queue":d.ChatQueueId=a.application.ChatQueueId}switch(a.application.intType){case"always":d.interval=c.join(","),delete a.application.IntervalId;break;case"custom":a.application.alwaysTime||(c[0]=a.application.alwaysTime?"*":a.application.t_from_hm+"-"+a.application.t_to_hm),a.application.wd_from&&a.application.wd_to&&"always"===a.application.wd_from&&"always"===a.application.wd_to?c[1]="*":c[1]=a.application.wd_from&&a.application.wd_to?a.application.wd_from+"-"+a.application.wd_to:"*",a.application.md_from&&a.application.md_to&&"always"===a.application.md_from&&"always"===a.application.md_to?c[2]="*":c[2]=a.application.md_from&&a.application.md_to?a.application.md_from+"-"+a.application.md_to:"*",a.application.m_from&&a.application.m_to&&"always"===a.application.m_from&&"always"===a.application.m_to?c[3]="*":c[3]=a.application.m_from&&a.application.m_to?a.application.m_from+"-"+a.application.m_to:"*",d.interval=c.join(","),delete a.application.IntervalId;break;case"list":d.IntervalId=a.application.IntervalId}b.post("/api/chat/applications",d).success(function(){h.path("/channels/chat/websites/view/"+f.websiteId+"/actions/list")}).error(function(a){console.error(a)})},a.formValidation=function(a){return a},a.next=function(){j.wizard().next()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.actions.wizard",{url:"/wizard",templateUrl:"app/channels/chat/website/view/action/wizard/wizard.html",controller:"ChatWebsiteViewActionWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.embedding",{url:"/embedding",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewEmbeddingViewCtrl",["$scope","$stateParams","$translate","clipboard","xAlert","ChatWebsite",function(a,b,c,d,e,f){a.initView=function(){return f.get({websiteId:b.websiteId,controller:"snippet"}).$promise.then(function(b){a.snippetCode=b.html})["catch"](function(a){e.show(a.message,"danger")})},a.copyToClipboard=function(){d.copyText(a.snippetCode),e.show(c.instant("MESSAGE_TEXT_COPIED_CLIPBOARD")+"!","success")}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.embedding.view",{url:"/view",templateUrl:"app/channels/chat/website/view/embedding/view/view.html",controller:"ChatWebsiteViewEmbeddingViewCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.form",{url:"/forms",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewFormViewCtrl",["$scope","$builder","$validator","$stateParams","$translate","ChatWebsite","xAlert",function(a,b,c,d,e,f,g){ -a.saveForm=function(a){var c=angular.copy(b.forms[a]);return c.length>3?g.show("You can insert at least 3 input elements","danger"):(_.forEach(c,function(a){delete a.id}),f.updateFields({websiteId:d.websiteId,controller:"fields",id:a},c).$promise.then(function(){g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.message,"danger")}))},a.getChatWebsiteFields=function(a){return f.query({websiteId:d.websiteId,controller:"fields",id:a}).$promise.then(function(c){_.forEach(c,function(c){b.addFormObject(a,c)})})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.form.view",{url:"/view",templateUrl:"app/channels/chat/website/view/form/view/view.html",controller:"ChatWebsiteViewFormViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewProactiveListCtrl",["$scope","gridOptions","ChatWebsite","$http","$translate","$stateParams","$uibModal",function(a,b,c,d,e,f,g){a.initProactiveActions=function(){var d={exporterCsvFilename:"telephones.csv",columnDefs:[{name:"name"},{name:"type"},{name:"action",width:125,buttons:[{"class":"blue-hoki",onClick:"grid.appScope.createItem(row.entity)",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a,{websiteId:f.websiteId,controller:"proactive"})},a.createItem=function(b){var c=g.open({animation:!0,templateUrl:"app/channels/chat/website/view/proactive/list/list.create.modal.html",controller:"ChatWebsiteProactiveListCreateCtrl",resolve:{item:b}});c.result.then(function(b){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteProactiveListCreateCtrl",["$scope","$translate","$uibModalInstance","$stateParams","ChatWebsite","xAlert","item",function(a,b,c,d,e,f,g){a.form={},a.item=g||{},a.title=g?b.instant("APPLICATION_EDIT_PROACTIVE_ACTION"):b.instant("APPLICATION_NEW_PROACTIVE_ACTION"),a.possibleType=[{type:"mouseOver",title:"Mouse Over"},{type:"timeout",title:"Timeout"}],a.save=function(){return g?e.update({websiteId:d.websiteId,controller:"proactive",id:a.item.id},a.item).$promise.then(function(a){f.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){f.show(a.data.message,"danger")}):e.save({websiteId:d.websiteId,controller:"proactive"},a.item).$promise.then(function(a){f.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){f.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.proactive.list",{url:"/list",templateUrl:"app/channels/chat/website/view/proactive/list/list.html",controller:"ChatWebsiteViewProactiveListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.proactive",{url:"/proactive",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.snippet",{url:"/snippet",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewSnippetViewCtrl",["$scope","$http","$stateParams","$translate","Template",function(a,b,c,d,e){a.$translate=d,a.statePreview={state:"online"},a.enquirySwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.lang={HeaderCurrentlyChatting:"Live Chat",HeaderOffline:"Contact us",OperatorOfflineMessage:"It appears as if all operators are currently offline.",OfflineMessage:"We're not online.
It doesn't mean we're not there to help - leave your message below and we'll be in touch as soon as possible.",EnquiryMessagePlaceholder:"Your message...",EnquiryButtonText:"Leave message",EnquirySubmitSuccess:"Your message was sucessfully submitted - we will contact you as soon as possible.",OperatorComposing:"{fullname} is typing...",FirstMessageText:"",ExitChatButtonText:"Exit Chat",ExitChatQuestionText:"Are you sure?",ExitChatButtonConfirmText:"Yes",ExitChatButtonCancelText:"No",MessagePlaceholderText:"Your message...",MessageSendButtonText:"Send",ValidationEmailRequired:"Please enter your email address",ValidationEmailInvalid:"Please enter a valid email address",ValidationEmailMaxLength:"The email address may not exceed 85 characters",ValidationUsernameRequired:"Please enter your name",ValidationUsernameMaxLength:"The name may not exceed 45 characters",ValidationEnquiryRequired:"Please enter your enquiry",ValidationEnquiryMaxLength:"The enquiry may not exceed 1500 characters",ValidationMessageRequired:"Please enter your message",ValidationMessageMaxLength:"The message may not exceed 750 characters"},a.initView=function(){e.get().$promise.then(function(b){console.log(b),a.mailTemplates=b.rows})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view.snippet.view",{url:"/view",templateUrl:"app/channels/chat/website/view/snippet/view/view.html",controller:"ChatWebsiteViewSnippetViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteViewCtrl",["$scope","xAlert","$http","$location","$stateParams","$translate","WizardHandler","ChatApplication","ChatWebsite",function(a,b,c,d,e,f,g,h,i){a.initApplication=function(){a.forms={},a.application={}},a.goNext=function(){g.wizard().next()},a.formValidation=function(a){return a},a.deleteItem=function(a){return h["delete"]({id:a}).$promise.then(function(){b.show(f.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(f.instant("Something went wrong!"),"danger")})},a.initView=function(){return i.get({id:e.websiteId}).$promise.then(function(b){a.chatWebsite=b})["catch"](function(a){b.show(a.message,"danger")})},a.updateItem=function(){return i.update({id:a.chatWebsite.id},a.chatWebsite).$promise.then(function(){b.show(f.instant("MESSAGE_CHAT_WEBSITE_UPDATE_SUCCESS")+"!","success")})["catch"](function(){b.show(f.instant("MESSAGE_CHAT_WEBSITE_UPDATE_FAILURE"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.view",{url:"/view/:websiteId",templateUrl:"app/channels/chat/website/view/view.html",controller:"ChatWebsiteViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites",{url:"/websites",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChatWebsiteWizardCtrl",["$scope","$http","$location","$translate","WizardHandler","xAlert","ChatWebsite",function(a,b,c,d,e,f,g){a.$translate=d,a.forms={formSetting:void 0,formAppearance:void 0,formLabel:void 0,formFunctionality:void 0},a.next=function(){e.wizard().next()},a.exitValidation=function(a){return a},a.item={},a.createItem=function(){return g.save(a.item).$promise.then(function(){f.show(d.instant("MESSAGE_CHAT_WEBSITE_CREATE_SUCCESS"),"success"),c.path("/channels/chat/websites/list")})["catch"](function(a){f.show(d.instant("MESSAGE_CHAT_WEBSITE_CREATE_FAILURE"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.chat.websites.wizard",{url:"/wizard",templateUrl:"app/channels/chat/website/wizard/wizard.html",controller:"ChatWebsiteWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.accounts",{url:"/accounts",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("FaxAccountListCtrl",["$scope","$http","xAlert","$translate","socket","Modal","$rootScope","$log","stResource",function(a,b,c,d,e,f,g,h,i){a.conf={faxAccountsByPage:{name:"10",value:10}},a.faxAccountsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.fax_accounts={checked:[]},a.check=function(b,c){c?a.fax_accounts.checked=angular.copy(_.map(a.displayedFaxAccounts,"id")):a.fax_accounts.checked=[]},a.initList=function(b){e.unsyncUpdates("fax_account"),b.url="/api/fax/accounts",i.getPage(b).then(function(c){a.displayedFaxAccounts=c.rows,b.pagination.numberOfPages=c.total_pages,g.updateTableConfig(a.faxAccountsByPage,a.displayedFaxAccounts.length),g.updateTableConfig(a.conf.faxAccountsByPage,a.displayedFaxAccounts.length)}),e.socket.on("fax_account:save",function(){a.initList(b)}),e.socket.on("fax_account:remove",function(c){a.fax_accounts.checked=_.without(a.fax_accounts.checked,c.id),a.initList(b)})},a.deleteItem=f.confirm["delete"](function(a){b["delete"]("api/fax/accounts/"+a).success(function(){c.show(d.instant("MESSAGE_FAX_ACCOUNT_DELETE_SUCCESS"),"success")}).error(function(){c.show(d.instant("MESSAGE_FAX_ACCOUNT_DELETE_FAILURE"),"danger")})}),a.deleteItems=f.confirm["delete"](function(){b["delete"]("/api/fax/accounts",{params:{id:a.fax_accounts.checked}}).success(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){c.show(d.instant(a.message),"danger")})}),a.getFaxAccounts=function(b){return _.map(a.faxAccountsByPage,function(a){var c={};return b.forEach(function(b){c[b]=a[b]}),c})},a.$on("$destroy",function(){e.unsyncUpdates("fax_account")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.accounts.list",{url:"/list",templateUrl:"app/channels/fax/account/list/list.html",controller:"FaxAccountListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("FaxAccountViewCtrl",["$scope","$http","$stateParams","$translate","$location","WizardHandler","socket","xAlert","Modal",function(a,b,c,d,e,f,g,h,i){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.forms={},a.sortableOptions={stop:function(){b.post("api/fax/accounts/"+c.id+"/applications",{applications:_.map(a.faxApplications,"id")}).success(function(b){a.faxApplications=b}).error(function(a){console.error(a)})},"ui-floating":!0},a.goNext=function(){f.wizard().next()},a.formValidation=function(a){return a},a.initApplication=function(){a.forms={},a.application={}},a.deleteItem=i.confirm["delete"](function(a){b["delete"]("api/fax/applications/"+a).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.getAppdata=function(b,c){switch(b){case"agent":return a.agents?_.find(a.agents,{id:c}).name:c;case"queue":return a.faxQueues?_.find(a.faxQueues,{id:c}).name:c}return"UNKNOWN"},a.createItem=function(){switch(a.application.appdata=a.application.appdata.id,a.application.app){case"agent":a.application.UserId=parseInt(a.application.appdata,10);break;case"queue":a.application.FaxQueueId=parseInt(a.application.appdata,10)}a.application.FaxAccountId=c.id,b.post("api/fax/applications",a.application).success(function(){e.path("/channels/fax/accounts/view/"+c.id+"/routes")}).error(function(){h.show("Something went wrong!","danger")})},a.$watch("application.app",function(c){if(c){var d;switch(c){case"agent":d="api/agents";break;case"queue":d="api/fax/queues"}b.get(d).success(function(b){a.items=b.rows})}},!0),a.initView=function(){b.get("/api/trunks").success(function(b){a.trunks=b.rows}).error(function(a){console.log(a)}),b.get("/api/fax/accounts/"+c.id).success(function(b){a.account=b}).error(function(){})},a.getAgents=function(){b.get("api/fax/agents").success(function(b){a.agents=b})},a.getFaxApplications=function(){b.get("/api/fax/applications",{params:{FaxAccountId:c.id}}).success(function(b){a.faxApplications=b,g.socket.on("fax_application:remove",function(b){_.remove(a.faxApplications,{id:b.id})})}),b.get("/api/agents").success(function(b){a.agents=b.rows}),b.get("/api/fax/queues").success(function(b){a.faxQueues=b.rows})},a.updateItemFaxAccount=function(){b.put("/api/fax/accounts/"+c.id,a.account).success(function(){h.show(d.instant("MESSAGE_FAX_ACCOUNT_UPDATE_SUCCESS")+".","success")}).error(function(){h.show(d.instant("MESSAGE_FAX_ACCOUNT_UPDATE_FAILURE")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.accounts.view",{url:"/view/:id",templateUrl:"app/channels/fax/account/view/view.html",controller:"FaxAccountViewCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]})}]}}).state("main.channels.fax.accounts.view.settings",{url:"/settings",templateUrl:"app/channels/fax/account/view/view.settings.html",authenticate:!0}).state("main.channels.fax.accounts.view.routes",{url:"/routes",templateUrl:"app/channels/fax/account/view/view.routes.html",authenticate:!0}).state("main.channels.fax.accounts.view.applications",{url:"/applications",templateUrl:"app/channels/fax/account/view/view.applications.html",authenticate:!0})}]),angular.module("xCallyShuttleApp").controller("FaxAccountWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initWizard=function(){a.$translate=d,a.forms={},a.item={},a.item.ecm=!1,a.item.minrate="9600",a.item.maxrate="33600",b.get("/api/trunks").success(function(b){a.trunks=b.rows}).error(function(a){console.error(a)})},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){b.post("api/fax/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_FAX_ACCOUNT_CREATE_SUCCESS")+".","success"),c.path("/channels/fax/accounts/list")}).error(function(){e.show(d.instant("MESSAGE_FAX_ACCOUNT_CREATE_FAILURE")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.accounts.wizard",{url:"/wizard",templateUrl:"app/channels/fax/account/wizard/wizard.html",controller:"FaxAccountWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax",{url:"/fax",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("FaxInboxComposeCtrl",["$scope","$http","FileUploader","$location","Auth","xAlert","$cookieStore","$translate",function(a,b,c,d,e,f,g,h){a.forms={},a.form={to:[],sto:[]},b.get("api/fax/accounts").success(function(b){a.faxAccounts=b.rows}),a.isNewMessageFromEmpty=!0;var i=a.uploader=new c({url:"api/fax/messages",queueLimit:1,withCredentials:!0,headers:{Authorization:"Bearer "+g.get("token")}});i.filters.push({name:"pdfFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|pdf|".indexOf(b)}}),i.onBeforeUploadItem=function(b){b.formData.push({accountId:a.form.from.id,toNum:a.form.sto[0],isNewRoom:a.isNewMessageFromEmpty,userId:e.getCurrentUser().id,html:a.form.html?a.form.html:""})},i.onSuccessItem=function(a,b,c,d){console.info("onSuccessItem",a,b,c,d)},i.onErrorItem=function(a,b,c,d){console.info("onErrorItem",a,b,c,d)},i.onCompleteAll=function(){i.clearQueue(),f.show(h.instant("MESSAGE_WELL_DONE"),"success"),d.path("/channels/fax/inbox/incoming")},i.onWhenAddingFileFailed=function(){f.show(h.instant("MESSAGE_WRONG_FORMAT"),"danger")},a.sendFax=function(){return a.form.sto.length?void(i.queue.length?i.uploadAll():b.post("api/fax/messages",{accountId:a.form.from.id,toNum:a.form.sto[0],isNewRoom:a.isNewMessageFromEmpty,userId:e.getCurrentUser().id,html:a.form.html,onlyText:!0}).success(function(){f.show(h.instant("MESSAGE_WELL_DONE"),"success"),d.path("/channels/fax/inbox/incoming")}).error(function(a){f.show(h.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger"),console.error(a)})):(a.forms.compose.to.$valid=!1,void(a.forms.compose.to.$invalid=!0))},a.cancel=function(){a.form.sto=[],delete a.form.from}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.inbox.compose",{url:"/compose",templateUrl:"app/channels/fax/inbox/room/room.html",controller:"FaxInboxComposeCtrl"})}]),angular.module("xCallyShuttleApp").controller("FaxInboxCtrl",["$scope","$http","$location","$translate","$timeout","$notification","Auth","socket","$interval",function(a,b,c,d,e,f,g,h,i){a.go=function(a,d,e){e?b.put("/api/fax/rooms/"+d,{status:e}).success(function(){c.path(a)}).error(function(a){console.error(a)}):c.path(a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.inbox",{url:"/inbox",templateUrl:"app/channels/fax/inbox/inbox.html",controller:"FaxInboxCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/inbox.css","assets/css/todo.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("FaxInboxIncomingCtrl",["$scope","$http","$location","socket","Auth","xAlert",function(a,b,c,d,e,f){a.$location=c,a.getRooms=function(){e.isAdmin()?b.get("api/fax/rooms").success(function(b){a.faxRooms=b,d.syncUpdates("fax_room",a.faxRooms)}).error(function(a){console.error(a),f.show($translate.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")}):b.get("api/fax/rooms/agent/"+e.getCurrentUser().id).success(function(b){a.faxRooms=b,d.socket.on("fax_room:update",function(b){b.UserId===e.getCurrentUser().id&&a.faxRooms.push(b)})}).error(function(a){f.show($translate.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger"),console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.inbox.incoming",{url:"/incoming",templateUrl:"app/channels/fax/inbox/incoming/incoming.html",controller:"FaxInboxIncomingCtrl"})}]),angular.module("xCallyShuttleApp").controller("FaxInboxRoomCtrl",["$scope","$http","$stateParams","$location","FileUploader","socket","Auth","xAlert","$translate","$cookieStore",function(a,b,c,d,e,f,g,h,i,j){function k(){a.lastMessage=_.reject(a.faxRoom.FaxMessages,function(a){return"RECEIVED"!==a.status}),a.lastMessage=_.sortByOrder(a.lastMessage,["id"],["desc"])[0],a.lastMessage&&(console.log(a.faxRoom),a.form.from=a.faxRoom.FaxAccount,a.form.to=[a.lastMessage.From.phone],a.form.sto=[a.lastMessage.From.phone])}var l=a.uploader=new e({url:"api/fax/messages",queueLimit:1,withCredentials:!0,headers:{Authorization:"Bearer "+j.get("token")}});l.filters.push({name:"pdfFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|pdf|".indexOf(b)}}),l.onBeforeUploadItem=function(b){console.log(a.form.from.id,a.form.sto[0],a.isNewMessageFromEmpty,c.id,g.getCurrentUser().id),b.formData.push({accountId:a.form.from.id,toNum:a.form.sto[0],isNewRoom:a.isNewMessageFromEmpty,roomId:c.id,userId:g.getCurrentUser().id,html:a.form.html}),console.log(b)},l.onSuccessItem=function(a,b,c,d){console.info("onSuccessItem",a,b,c,d)},l.onErrorItem=function(a,b,c,d){console.info("onErrorItem",b,c,d)},l.onCompleteAll=function(){l.clearQueue(),h.show(i.instant("MESSAGE_WELL_DONE"),"success")},l.onWhenAddingFileFailed=function(){h.show(i.instant("MESSAGE_WRONG_FORMAT"),"danger")},a.initRoomView=function(){a.isNewMessageFromEmpty=!0,a.Auth=g,a.forms={},a.form={to:[],sto:[]},b.get("api/agents").success(function(b){a.agents=b}),b.get("api/fax/accounts").success(function(b){a.faxAccounts=b.rows}),c.id&&b.get("/api/fax/rooms/"+c.id).success(function(b){a.faxRoom=b,a.isNewMessageFromEmpty=!1,f.syncUpdates("fax_message",[],function(b,c){"created"===b&&c.FaxRoomId===a.faxRoom.id&&(a.faxRoom.FaxMessages.push(c),k())}),k()}).error(function(a){console.error(a),h.show(i.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.sendFax=function(){return a.form.sto.length?void(l.queue.length?l.uploadAll():b.post("api/fax/messages",{accountId:a.form.from.id,toNum:a.form.sto[0],isNewRoom:a.isNewMessageFromEmpty,userId:g.getCurrentUser().id,html:a.form.html,onlyText:!0}).success(function(){h.show(i.instant("MESSAGE_WELL_DONE"),"success"),console.log("Fax Message sent")}).error(function(a){h.show(i.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger"),console.error(a)})):(a.forms.compose.to.$valid=!1,void(a.forms.compose.to.$invalid=!0))},a.assignAgent=function(a){b.put("/api/fax/rooms/"+c.id,{UserId:a}).success(function(){h.show(i.instant("MESSAGE_WELL_DONE"),"danger")}).error(function(){h.show(i.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.updateStatus=function(d){b.put("/api/fax/rooms/"+c.id,{status:d}).success(function(b){a.faxRoom.status=b.status,h.show(i.instant("MESSAGE_WELL_DONE"),"danger")}).error(function(a){console.error(a),h.show(i.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.cancel=function(){a.form.sto=[],delete a.form.from,l.clearQueue()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.inbox.room",{url:"/room/:id",templateUrl:"app/channels/fax/inbox/room/room.html",controller:"FaxInboxRoomCtrl"})}]),angular.module("xCallyShuttleApp").factory("FaxQueue",["$resource",function(a){return a("/api/fax/queues/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("FaxQueueListCtrl",["$scope","FaxQueue","gridOptions","$uibModal",function(a,b,c,d){a.initView=function(){var d={exporterCsvFilename:"fax_queues.csv",columnDefs:[{name:"name"},{name:"description"},{name:"strategy"},{name:"timeout"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/fax/queues/view/{{row.entity.id}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){var b=d.open({animation:!0,templateUrl:"app/channels/fax/queue/list/list.create.modal.html",controller:"FaxQueueListCreateCtrl"});b.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("FaxQueueListCreateCtrl",["$scope","$uibModalInstance","$translate","xAlert","FaxQueue",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return e.save(a.item).$promise.then(function(a){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),b.close(a)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.queues.list",{url:"/list",templateUrl:"app/channels/fax/queue/list/list.html",controller:"FaxQueueListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.queues",{url:"/queues",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("FaxQueueViewCtrl",["$scope","$http","$translate","$stateParams","xAlert","FaxQueue","Team",function(a,b,c,d,e,f,g){var h=function(){return{select:function(b){return f.save({id:a.queue.id,controller:"agents"},{agents:b,penalty:a.queue.penalty}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.error(a)})},deselect:function(b){return f["delete"]({id:a.queue.id,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.error(a)})}}};a.getQueue=function(){return f.get({id:d.id}).$promise.then(function(b){b.penalty=0,a.queue=b})["catch"](function(a){e.show(a.message,"danger")})},a.updateFaxQueue=function(){return f.update({id:d.id},{name:a.queue.name,description:a.queue.description,timeout:a.queue.timeout,strategy:a.queue.strategy}).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.message,"danger")})},a.getTeams=function(){return g.get().$promise.then(function(b){return a.teams=b.rows,f.query({id:d.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindMailQueue(a.teams,_.map(b,function(a){return{id:a.id,penalty:a.UserHasFaxQueue.penalty}}),h)})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.queues.view",{url:"/view/:id",templateUrl:"app/channels/fax/queue/view/view.html",controller:"FaxQueueViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.fax.queues.view.settings",{url:"/settings",templateUrl:"app/channels/fax/queue/view/view.settings.html"}).state("main.channels.fax.queues.view.agents",{url:"/agents",templateUrl:"app/channels/fax/queue/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.realtime",{url:"/realtime",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("FaxRealtimeViewAgentCtrl",["$scope","$log","$uibModal","$translate","socket","xAlert","Agent","Pause","Action","FaxQueue","usSpinnerService","$q","uiGridConstants",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){return k.spin("spinner-grid"),g.get(s).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.data=[],b.rows.forEach(function(a){p(a)})})["catch"](function(a){f.show(a.message,"danger")})["finally"](function(){k.stop("spinner-grid")})}function o(){e.socket.on("agent:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.id,isAgent:!0});if(c){var d=a.gridOptions.data.indexOf(c);a.gridOptions.data[d].online=b.online,a.gridOptions.data[d].lastLoginAt=b.lastLoginAt,a.gridOptions.data[d].pause=b.faxPause,a.gridOptions.data[d].pauseType=b.pauseType,a.gridOptions.data[d].lastPauseAt=b.lastPauseAt,a.gridOptions.data[d].ipaddr=b.ipaddr,a.gridOptions.data[d].port=b.port,a.gridOptions.data[d].fullcontact=b.fullcontact,a.gridOptions.data[d].useragent=b.useragent,a.gridOptions.data[d].lastms=b.lastms,a.gridOptions.data[d].internal=b.internal,_.map(a.gridOptions.data,function(a){a.isAgent||a.agentId!==b.id||(a.online=b.online)})}}),e.socket.on("agent:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.id})}),e.socket.on("user_has_fax_queue:save",function(b){console.log("new queue",b);var c=_.find(a.gridOptions.data,{agentId:b.UserId,isAgent:!0}),d=a.gridOptions.data.indexOf(c);a.gridOptions.data.splice(d+1,0,{isAgent:!1,agentId:b.UserId,queue:b.queue,queueId:b.FaxQueueId,agent:b.membername,online:c.online})}),e.socket.on("user_has_fax_queue:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.UserId,queueId:b.FaxQueueId})})}function p(b){a.gridOptions.data.push({isAgent:!0,agentId:b.id,agent:b.name,online:b.online,lastLoginAt:b.lastLoginAt,lastPauseAt:b.lastPauseAt,pause:b.faxPause,pauseType:b.pauseType,ipaddr:b.ipaddr,port:b.port,fullcontact:b.fullcontact,useragent:b.useragent,lastms:b.lastms,internal:b.internal,$$treeLevel:0}),b.FaxQueues.forEach(function(c){a.gridOptions.data.push({isAgent:!1,agentId:b.id,queue:c.name,queueId:c.id,agent:b.name,online:b.online})})}function q(){return h.get().$promise.then(function(b){a.pauses=b.rows,e.syncUpdates("pause",a.pauses)})["catch"](function(a){f.show(a.message,"danger")})}function r(){return j.get().$promise.then(function(b){a.faxQueues=b.rows,e.syncUpdates("fax_queue",a.faxQueues)})["catch"](function(a){f.show(a.message,"danger")})}a.faxQueues=[];var s={offset:0,limit:10};a.moment=moment,a.initAgents=function(){a.gridOptions={enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,showTreeExpandNoChildren:!0,columnDefs:[{name:"name",displayName:"APPLICATION_AGENT",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.agent}} <{{row.entity.internal}}>
'},{name:"online",displayName:"APPLICATION_ONLINE",width:150,headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
({{hhours}}:{{mminutes}}:{{sseconds}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"ONLINE"},{value:"false",label:"OFFLINE"}]}},{name:"faxPause",width:300,displayName:"APPLICATION_PAUSE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{hhours}}:{{mminutes}}:{{sseconds}}({{row.entity.pauseType}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"PAUSED"},{value:"false",label:"NOT PAUSED"}]},enableSorting:!1,enableColumnMenu:!1},{name:"queue",displayName:"APPLICATION_QUEUE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",displayName:"",width:170,cellClass:"text-center ui-grid-vcenter",cellTemplate:'
', -enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1}],data:[],gridMenuTitleFilter:function(a){var b=l.defer();return b.resolve(d.instant(a)),b.promise},onRegisterApi:function(b){a.gridApi=b,a.gridApi.grid.registerDataChangeCallback(function(){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length)}),a.gridApi.treeBase.on.rowExpanded(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length+b.treeNode.children.length)}),a.gridApi.treeBase.on.rowCollapsed(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length-b.treeNode.children.length)}),a.gridApi.core.on.sortChanged(a,function(a,b){0===b.length?s.order=null:s.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),n()}),a.gridApi.pagination.on.paginationChanged(a,function(a,b){s.offset=(a-1)*b,s.limit=b,n()}),a.gridApi.core.on.filterChanged(a,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?s[a.name]=a.filters[0].term:delete s[a.name]}),n()})}},n(),q(),r(),o()};var t=function(a){var b=a?30*a+130:270;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px"),angular.element(document.getElementsByClassName("ui-grid-viewport")).css("height",30*a+"px")};a.$on("$destroy",function(){e.unsyncUpdates("agent"),e.unsyncUpdates("user_has_fax_queue")}),a.pause=function(a,b,c){return i.save({name:b,agent:a,type:c||"DEFAULT PAUSE",data4:c||"DEFAULT PAUSE",channel:"fax"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.joinQueue=function(e){var g=c.open({animation:!0,templateUrl:"app/channels/fax/realtime/view/agent/queue.modal.add.html",controller:"FaxRealtimeViewAgentQueueModalCtrl",resolve:{queues:function(){return _.reject(a.faxQueues,function(b){return _.find(a.gridOptions.data,{queue:b.name,isAgent:!1,agentId:e})?!0:!1})}}});g.result.then(function(b){return i.save({name:"QueueAdd",agent:e,queues:_.filter(a.faxQueues,function(a){return _.includes(b.queues,a.id)}),channel:"fax",data1:e,data3:b.queues.join(","),data4:"fax"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},function(){b.info("Modal dismissed at: "+new Date)})},a.leaveQueue=function(a,b){return i.save({name:"QueueRemove",agent:a,queueId:b,channel:"fax",data1:a,data3:b,data4:"fax"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.showInfo=function(a){c.open({animation:!0,templateUrl:"app/channels/fax/realtime/view/agent/agent.modal.info.html",controller:"FaxRealtimeViewAgentInfoModalCtrl",resolve:{agent:a}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.realtime.view.agents",{url:"/agents",templateUrl:"app/channels/fax/realtime/view/agent/agent.html",controller:"FaxRealtimeViewAgentCtrl"})}]),angular.module("xCallyShuttleApp").controller("FaxRealtimeViewAgentInfoModalCtrl",["$scope","$uibModalInstance","$http","agent",function(a,b,c,d){a.agent=d,a.close=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("FaxRealtimeViewAgentQueueModalCtrl",["$scope","$uibModalInstance","$http","queues",function(a,b,c,d){a.queues=d,a.item={},a.save=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("FaxRealtimeViewCtrl",["$scope","$state",function(a,b){a.agents=[{name:"Queues",link:"main.channels.fax.realtime.view.agents.queues"},{name:"Timeline",link:"main.channels.fax.realtime.view.agents.timeline"}],a.sessions=[{name:"Sessions",link:"main.channels.fax.realtime.view.sessions"}],a.tree={queues:[{name:"Queues",link:"main.channels.fax.realtime.view.agents.queues"},{name:"Timeline",link:"main.channels.fax.realtime.view.agents.timeline"}],sessions:[{name:"Sessions",link:"main.channels.fax.realtime.view.sessions"}]}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.fax.realtime.view",{url:"/view",templateUrl:"app/channels/fax/realtime/view/view.html",controller:"FaxRealtimeViewCtrl"})}]),angular.module("xCallyShuttleApp").factory("MailAccount",["$resource",function(a){return a("/api/mail/accounts/:accountId/:controller/:id",{id:"@accountId"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts",{url:"/accounts",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("MailAccountListCtrl",["$scope","gridOptions","MailAccount","$stateParams",function(a,b,c,d){a.initView=function(){var e={exporterCsvFilename:"mail_accounts.csv",columnDefs:[{name:"name"},{name:"description"},{name:"address"},{name:"MailServerIn.state",width:100,cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.MailServerIn.state}}
",displayName:"IMAP",enableSorting:!1,enableFiltering:!1},{name:"MailServerOut.state",width:110,cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.MailServerOut.state}}
",displayName:"SMTP",enableSorting:!1,enableFiltering:!1},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/mail/accounts/view/{{row.entity.id}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,e,a,{accountId:d.accountId})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.list",{url:"/list",templateUrl:"app/channels/mail/account/list/list.html",controller:"MailAccountListCtrl"})}]),angular.module("xCallyShuttleApp").factory("MailServerIn",["$resource",function(a){return a("/api/mail/servers/in/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("MailServerOut",["$resource",function(a){return a("/api/mail/servers/out/:id/:controller",{id:"@id"},{update:{method:"PUT"},test:{method:"GET"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view.actions",{url:"/actions",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("MailAccountViewActionListCtrl",["$scope","gridOptions","MailAccount","$http","$translate","$stateParams",function(a,b,c,d,e,f){a.initActons=function(){var d={draggable:!0,exporterCsvFilename:"mail_applications.csv",enableSorting:!1,enableFiltering:!1,columnDefs:[{name:"app",cellClass:"text-center"},{name:"name",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.MailQueue ? row.entity.MailQueue.name : row.entity.User.name}}
"},{name:"timeout",cellClass:"text-center"},{name:"interval",cellClass:"text-center"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/mail/accounts/view/{{row.entity.MailAccountId}}/actions/view/{{row.entity.id}}",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.app, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a,{accountId:f.accountId,controller:"applications"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view.actions.list",{url:"/list",templateUrl:"app/channels/mail/account/view/action/list/list.html",controller:"MailAccountViewActionListCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailAccountViewActionViewCtrl",["$scope","$http","$stateParams","$translate","$location","xAlert","WizardHandler","socket","application","interval","Agent","Interval","MailQueue",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initAction=function(){a.$application=i.application,a.$stateParams=c,a.$interval=j.interval,a.forms={},a.apps=[{name:"Queue",value:"queue"},{name:"Agent",value:"agent"}],b.get("/api/mail/applications/"+c.actionId).success(function(b){if(a.application=b,a.application.alwaysTime=!1,a.application.IntervalId)a.application.intType="list";else switch(a.application.interval){case"*,*,*,*":a.application.intType="always";break;default:a.application.intType="custom"}var c=a.application.interval.split(",");"*"===c[0]?a.application.alwaysTime=!0:(a.application.t_from=moment(new Date),a.application.t_to=moment(new Date),a.application.t_from.hour(c[0].split("-")[0].split(":")[0]),a.application.t_from.minute(c[0].split("-")[0].split(":")[1]),a.application.t_to.hour(c[0].split("-")[1].split(":")[0]),a.application.t_to.minute(c[0].split("-")[1].split(":")[1])),"*"===c[1]?(a.application.wd_from="always",a.application.wd_to="always"):(a.application.wd_from=c[1].split("-")[0],a.application.wd_to=c[1].split("-")[1]),"*"===c[2]?(a.application.md_from="always",a.application.md_to="always"):(a.application.md_from=c[2].split("-")[0],a.application.md_to=c[2].split("-")[1]),"*"===c[3]?(a.application.m_from="always",a.application.m_to="always"):(a.application.m_from=c[3].split("-")[0],a.application.m_to=c[3].split("-")[1]),a.$watch("application.t_from",function(b){a.application.t_from_hm=moment(b).format("HH:mm")}),a.$watch("application.t_to",function(b){a.application.t_to_hm=moment(b).format("HH:mm")})}).error(function(a){console.error(a)})},a.getQueues=function(){return m.get().$promise.then(function(b){a.queues=b.rows})["catch"](function(a){console.error(a)})},a.getAgents=function(){return k.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)})},a.getIntervals=function(){return l.get().$promise.then(function(b){a.intervals=b.rows})["catch"](function(a){console.error(a)})},a.updateItem=function(){var e=["*","*","*","*"],g={app:a.application.app,timeout:a.application.timeout,MailAccountId:c.id};switch(a.application.app){case"agent":g.UserId=a.application.UserId;break;case"queue":g.MailQueueId=a.application.MailQueueId}switch(a.application.intType){case"always":g.interval=e.join(","),delete a.application.IntervalId;break;case"custom":a.application.alwaysTime||(e[0]=a.application.alwaysTime?"*":a.application.t_from_hm+"-"+a.application.t_to_hm),a.application.wd_from&&a.application.wd_to&&"always"===a.application.wd_from&&"always"===a.application.wd_to?e[1]="*":e[1]=a.application.wd_from&&a.application.wd_to?a.application.wd_from+"-"+a.application.wd_to:"*",a.application.md_from&&a.application.md_to&&"always"===a.application.md_from&&"always"===a.application.md_to?e[2]="*":e[2]=a.application.md_from&&a.application.md_to?a.application.md_from+"-"+a.application.md_to:"*",a.application.m_from&&a.application.m_to&&"always"===a.application.m_from&&"always"===a.application.m_to?e[3]="*":e[3]=a.application.m_from&&a.application.m_to?a.application.m_from+"-"+a.application.m_to:"*",g.interval=e.join(","),delete a.application.IntervalId;break;case"list":g.IntervalId=a.application.IntervalId}b.put("/api/mail/applications/"+c.actionId,g).success(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){f.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view.actions.view",{url:"/view/:actionId",templateUrl:"app/channels/mail/account/view/action/view/view.html",controller:"MailAccountViewActionViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailAccountViewActionWizardCtrl",["$scope","$http","Agent","MailQueue","Interval","$stateParams","$translate","$location","xAlert","WizardHandler","socket","application","interval",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initWizard=function(){a.apps=[{name:"Queue",value:"queue"},{name:"Agent",value:"agent"}],a.$application=l.application,a.$stateParams=f,a.$interval=m.interval,a.forms={},a.application={alwaysTime:!0},a.$watch("application.t_from",function(b){a.application.t_from_hm=moment(b).format("HH:mm")}),a.$watch("application.t_to",function(b){a.application.t_to_hm=moment(b).format("HH:mm")})},a.getQueues=function(){return d.get().$promise.then(function(b){a.queues=b.rows})["catch"](function(a){console.error(a)})},a.getAgents=function(){return c.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)})},a.getIntervals=function(){return e.get().$promise.then(function(b){a.intervals=b.rows})["catch"](function(a){console.error(a)})},a.createItem=function(){var c=["*","*","*","*"],d={app:a.application.app,timeout:a.application.timeout,MailAccountId:f.accountId};switch(a.application.app){case"agent":d.UserId=a.application.UserId;break;case"queue":d.MailQueueId=a.application.MailQueueId}switch(a.application.intType){case"always":d.interval=c.join(","),delete a.application.IntervalId;break;case"custom":a.application.alwaysTime||(c[0]=a.application.alwaysTime?"*":a.application.t_from_hm+"-"+a.application.t_to_hm),a.application.wd_from&&a.application.wd_to&&"always"===a.application.wd_from&&"always"===a.application.wd_to?c[1]="*":c[1]=a.application.wd_from&&a.application.wd_to?a.application.wd_from+"-"+a.application.wd_to:"*",a.application.md_from&&a.application.md_to&&"always"===a.application.md_from&&"always"===a.application.md_to?c[2]="*":c[2]=a.application.md_from&&a.application.md_to?a.application.md_from+"-"+a.application.md_to:"*",a.application.m_from&&a.application.m_to&&"always"===a.application.m_from&&"always"===a.application.m_to?c[3]="*":c[3]=a.application.m_from&&a.application.m_to?a.application.m_from+"-"+a.application.m_to:"*",d.interval=c.join(","),delete a.application.IntervalId;break;case"list":d.IntervalId=a.application.IntervalId}b.post("/api/mail/applications",d).success(function(){h.path("/channels/mail/accounts/view/"+f.accountId+"/actions/list")}).error(function(a){console.error(a)})},a.formValidation=function(a){return a},a.next=function(){j.wizard().next()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view.actions.wizard",{url:"/wizard",templateUrl:"app/channels/mail/account/view/action/wizard/wizard.html",controller:"MailAccountViewActionWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailAccountViewCtrl",["$scope","$http","$stateParams","$translate","$location","$timeout","socket","xAlert","MailAccount","MailMessage","MailServerIn","MailServerOut","usSpinnerService",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.CONST_TIMEOUT=3e4,a.$on("$destroy",function(){g.socket.removeAllListeners("mail_message:sent"),g.socket.removeAllListeners("mail_message:failed")}),a.initView=function(){return g.socket.on("mail_message:sent",function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success"),m.stop("spinner-grid")}),g.socket.on("mail_message:failed",function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger"),m.stop("spinner-grid")}),i.get({id:c.accountId}).$promise.then(function(b){a.account=b})["catch"](function(a){h.show(a.message,"danger")})},a.updateItemMailAccount=function(){return i.update({id:c.accountId},{name:a.account.name,description:a.account.description,address:a.account.address,fidelity:a.account.fidelity,timeout:a.account.timeout}).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})},a.updateItemMailServerIn=function(){return k.update({id:a.account.MailServerIn.id},a.account.MailServerIn).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})},a.updateItemMailServerOut=function(){return l.update({id:a.account.MailServerOut.id},a.account.MailServerOut).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})},a.test=function(){return m.spin("spinner-grid"),l.test({id:a.account.MailServerOut.id,controller:"test"}).$promise["finally"](function(){f(function(){m.stop("spinner-grid")},a.CONST_TIMEOUT)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.view",{url:"/view/:accountId",templateUrl:"app/channels/mail/account/view/view.html",controller:"MailAccountViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]})}]}}).state("main.channels.mail.accounts.view.settings",{url:"/settings",templateUrl:"app/channels/mail/account/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("MailAccountWizardCtrl",["$scope","$http","$location","$translate","WizardHandler","xAlert","MailAccount",function(a,b,c,d,e,f,g){a.isActive=!0,a.size="small",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initWizard=function(){a.forms={},a.item={MailServerIn:{port:993,ssl:!0,"delete":!1,protocol:"IMAP",filter:"UNSEEN",mailbox:"INBOX",keepalive:!0,authTimeout:5,connTimeout:10},MailServerOut:{port:465,ssl:!0}}},a.goNext=function(){e.wizard().next()},a.formValidation=function(a){return a},a.createItem=function(){return g.save(a.item).$promise.then(function(){c.path("/channels/mail/accounts/list")})["catch"](function(a){f.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.accounts.wizard",{url:"/wizard",templateUrl:"app/channels/mail/account/wizard/wizard.html",controller:"MailAccountWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.inbox",{url:"/inbox",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("MailInboxListCtrl",["$scope","$rootScope","$uibModal","MailRoom","gridOptions","uiGridConstants","Auth",function(a,b,c,d,e,f,g){a.loadAgents=function(a){c.open({animation:!0,templateUrl:"app/channels/mail/inbox/view/view.agents.modal.html",controller:"MailInboxViewModalAgentCtrl",resolve:{roomId:a}})},a.initView=function(){var c={exporterCsvFilename:"mail_rooms.csv",enableRowHeaderSelection:g.isAdmin(),columnDefs:[{name:"id",displayName:"",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
#{{row.entity.id}}
",width:75,enableSorting:!1,enableFiltering:!1},{name:"subject"},{name:"from",cellClass:"text-center"},{name:"MailAccount.name",displayName:"Account",cellClass:"text-center",enableSorting:!1,enableFiltering:!1},{name:"users",displayName:"APPLICATION_AGENTS",cellClass:"ui-grid-vcenter",cellTemplate:"
{{(row.entity.Users | map:'fullname').join(', ')}}
",enableSorting:!1,enableFiltering:!1},{name:"status",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{row.entity.status}}
",filter:{type:f.filter.SELECT,selectOptions:[{value:"NEW",label:"NEW"},{value:"OPEN",label:"OPEN"},{value:"CLOSED",label:"CLOSED"}]},width:100},{name:"createdAt",displayName:"",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
',enableSorting:!1,enableFiltering:!1,width:125},{name:"action",width:175,buttons:[{"class":"blue-hoki",href:"/channels/mail/inbox/view/{{row.entity.id}}/room",name:"open"},{"class":"green-meadow",href:"#",name:"agents",onClick:"grid.appScope.loadAgents(row.entity.id)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.id, row.entity.id)",hide:!g.isAdmin()}]}]};a.gridOptions=e.gridOptions(d,c,a),b.$on("mailMessageEvent",function(){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.inbox.list",{url:"/list",templateUrl:"app/channels/mail/inbox/list/list.html",controller:"MailInboxListCtrl"})}]),angular.module("xCallyShuttleApp").directive("mail",function(){return{templateUrl:"app/channels/mail/inbox/mail/mail.html",restrict:"EA",scope:{mailMessage:"=message"}}}),angular.module("xCallyShuttleApp").directive("note",function(){return{templateUrl:"app/channels/mail/inbox/note/note.html",restrict:"EA",scope:{mailMessage:"=message"}}}),angular.module("xCallyShuttleApp").controller("MailInboxViewModalAgentCtrl",["$scope","$uibModalInstance","$translate","$stateParams","Agent","MailRoom","xAlert","roomId",function(a,b,c,d,e,f,g,h){console.log("roomId",h),a.initModal=function(){a.agents=[],a.item={agents:[]},e.get().$promise.then(function(b){b.rows.forEach(function(b){a.agents.push(b)})})["catch"](function(a){console.error(a)}),f.query({id:d.id||h,controller:"agents"}).$promise.then(function(b){b.forEach(function(b){a.agents.push(b),a.item.agents.push(b.id)})})["catch"](function(a){console.error(a)}),a.modal={dismissable:!0,title:"APPLICATION_MESSAGE_SEND_RETRY",text:"MESSAGE_MESSAGE_SEND_RETRY",buttons:[{classes:"btn btn-success",text:"APPLICATION_RETRY",click:function(a){b.close(a)}},{classes:"btn default",text:"APPLICATION_CANCEL",click:function(a){b.dismiss(a)}}]}},a.ok=function(){return f.update({id:d.id||h,controller:"agents",agents:a.item.agents}).$promise.then(function(){g.show(c.instant("MESSAGE_WELL_DONE"),"success"),b.close()})["catch"](function(a){console.error(a)})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("MailInboxViewCtrl",["$scope","$location","$cookieStore","$stateParams","$translate","$uibModal","CannedAnswer","socket","Agent","MailAccount","MailRoom","MailAttachment","MailMessage","FileUploader","Auth","xAlert","usSpinnerService",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q){var r,s=[];a.onSelectAnswer=function(b){a.form.html+=b,a.selectedAnswer=""},a.getAnswers=function(a){return g.get({key:a}).$promise.then(function(a){return _.map(a.rows,"value")})},a.initRoom=function(){a.Auth=o,a.config={autoHideScrollbar:!1,theme:"light",advanced:{updateOnContentResize:!0},setHeight:781,scrollInertia:0},a.forms={},a.selectedAnswer="",a.form={disabled:!1,from:[],to:[],sto:[],cc:[],scc:[],html:""},h.socket.on("mail_message:save",function(b){return a.mailRoom&&b.MailRoomId===d.id?m.get({id:b.id}).$promise.then(function(b){a.mailRoom.MailMessages.unshift(b)})["catch"](function(a){console.error(a)}):void 0}),r=a.uploader=new n({url:"api/mail/attachments",autoUpload:!0,withCredentials:!0,headers:{Authorization:"Bearer "+c.get("token")}}),r.removeFromQueue=function(a){var b=this;return l["delete"]({id:a.basename}).$promise.then(function(){var c=b.getIndexOfItem(a),d=b.queue[c];d.isUploading&&d.cancel(),b.queue.splice(c,1),d._destroy(),b.progress=b._getTotalProgress(),s=_.reject(s,{basename:a.basename})})["catch"](function(){p.show(e.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},r.onErrorItem=function(){p.show(e.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")},r.onSuccessItem=function(a,b){var c={size:b.size,path:b.path,name:b.name,basename:b.basename,type:b.type};a=_.merge(a,c),s.push(c)},i.get().$promise.then(function(b){a.agents=b.rows})["catch"](function(a){console.error(a)}),j.get().$promise.then(function(b){a.mailAccounts=b.rows})["catch"](function(a){console.error(a)}),d.id&&k.get({id:d.id}).$promise.then(function(b){a.mailRoom=b,a.form.from.push(b.MailAccount.address);var c=_.last(a.mailRoom.MailMessages);a.form.to=a.form.cc=a.form.bcc=_.union(c.from,c.to,c.cc,c.bcc),a.form.sto=_.remove(a.form.to,function(a){return a!==b.MailAccount.address}),"NEW"===a.mailRoom.status&&k.update({id:d.id},{status:"OPEN"})})["catch"](function(a){console.error(a)})},a.cancel=function(){a.form.disabled=!1,a.form.from=[],a.form.to=[],a.form.sto=[],a.form.cc=[],a.form.scc=[],delete a.form.subject,delete a.form.html},a.updateStatus=function(a){return k.update({id:d.id},{status:a}).$promise.then(function(){p.show(e.instant("MESSAGE_STATUS_UPDATE_SUCCESS"),"success"),b.path("/channels/mail/inbox/list")})["catch"](function(a){p.show(a.message,"danger")})},a.loadAgents=function(){f.open({animation:!0,templateUrl:"app/channels/mail/inbox/view/view.agents.modal.html",controller:"MailInboxViewModalAgentCtrl"})},a.loadTemplate=function(){f.open({animation:!0,templateUrl:"app/channels/mail/inbox/view/view.templates.modal.html",controller:"MailInboxViewModalTemplateCtrl"}).result.then(function(b){a.form.subject=b.template.subject,a.form.html=b.template.html})},a.loadNote=function(){f.open({animation:!0,templateUrl:"app/channels/mail/inbox/view/view.notes.modal.html",controller:"MailInboxViewModalNoteCtrl"})},a.sendMail=function(){var c={},f={subject:a.mailRoom?a.mailRoom.subject:a.form.subject,from:a.form.from,to:a.form.sto||[],cc:a.form.scc||[],html:a.form.html||null,text:a.form.text||null,inReplyTo:c.messageId||null,status:"SENDING",MailAttachments:s};return q.spin("spinner-grid"),a.form.disabled=!0,a.mailRoom?(c=_.last(a.mailRoom.MailMessages,{status:"RECEIVED"}),f.inReplyTo=c.messageId||null,k.save({id:d.id,controller:"messages"},f).$promise.then(function(){p.show(e.instant("MESSAGE_WELL_DONE"),"success"),b.path("/channels/mail/inbox/list")})["catch"](function(){p.show(e.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})["finally"](function(){q.stop("spinner-grid"),a.form.disabled=!1})):m.save(f).$promise.then(function(){p.show(e.instant("MESSAGE_MAIL_MESSAGE_SEND_SUCCESS"),"success"),b.path("/channels/mail/inbox/list")})["catch"](function(){p.show(e.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})["finally"](function(){q.stop("spinner-grid"),a.form.disabled=!1})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.inbox.view",{url:"/view",templateUrl:"app/channels/mail/inbox/view/view.html"}).state("main.channels.mail.inbox.view.compose",{url:"/compose",templateUrl:"app/channels/mail/inbox/view/view.room.html",controller:"MailInboxViewCtrl"}).state("main.channels.mail.inbox.view.room",{url:"/:id/room",templateUrl:"app/channels/mail/inbox/view/view.room.html",controller:"MailInboxViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailInboxViewModalNoteCtrl",["$scope","$uibModalInstance","$stateParams","$translate","MailRoom","xAlert",function(a,b,c,d,e,f){a.initModal=function(){a.item={}},a.ok=function(){return e.save({id:c.id,controller:"messages"},{text:a.item.text,status:"NOTE"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(){f.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})["finally"](function(){b.close()})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("MailInboxViewModalTemplateCtrl",["$scope","$uibModalInstance","Template",function(a,b,c){a.initModal=function(){return a.item={},c.get().$promise.then(function(b){a.templates=b.rows})["catch"](function(a){console.error(a)})},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail",{url:"/mail",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("MailAttachment",["$resource",function(a){return a("/api/mail/attachments/:id/:controller",{id:"@id"})}]),angular.module("xCallyShuttleApp").factory("MailMessage",["$resource",function(a){return a("/api/mail/messages/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("MailReport",["$resource",function(a){return a("/api/report/mails/:id/:controller1/:controller2",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("MailRoom",["$resource",function(a){return a("/api/mail/rooms/:id/:controller",{id:"@id",controller:"@controller"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("MailQueueListCtrl",["$scope","MailQueue","gridOptions","$uibModal","xAlert",function(a,b,c,d,e){a.initView=function(){var d={exporterCsvFilename:"voice_queues.csv",columnDefs:[{name:"name"},{name:"description"},{name:"timeout"},{name:"strategy"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/mail/queues/view/{{row.entity.id}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){var b=d.open({animation:!0,templateUrl:"app/channels/mail/queue/list/list.create.modal.html",controller:"MailQueueListCreateCtrl"});b.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("MailQueueListCreateCtrl",["$scope","$uibModalInstance","$translate","xAlert","MailQueue",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return e.save(a.item).$promise.then(function(a){b.close(a)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.queues.list",{url:"/list",templateUrl:"app/channels/mail/queue/list/list.html",controller:"MailQueueListCtrl"})}]),angular.module("xCallyShuttleApp").factory("MailQueue",["$resource",function(a){return a("/api/mail/queues/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.queues",{url:"/queues",template:"
","abstract":!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/scripts/components-dropdowns.js"]})}]},data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("MailQueueViewCtrl",["$scope","$http","$translate","$stateParams","xAlert","Team","MailQueue",function(a,b,c,d,e,f,g){var h=function(){return{select:function(b){return g.save({id:a.queue.id,controller:"agents"},{agents:b,penalty:a.queue.penalty}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.error(a)})},deselect:function(b){return g["delete"]({id:a.queue.id,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.error(a)})}}};a.getQueue=function(){return g.get({id:d.id}).$promise.then(function(b){b.penalty=0,a.queue=b})["catch"](function(a){console.error(a)})},a.updateMailQueue=function(){return g.update({id:d.id},{name:a.queue.name,description:a.queue.description,timeout:a.queue.timeout,strategy:a.queue.strategy}).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})},a.getTeams=function(){return f.get().$promise.then(function(b){return a.teams=b.rows,g.query({id:d.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindMailQueue(a.teams,_.map(b,function(a){return{id:a.id,penalty:a.UserHasMailQueue.penalty}}),h)})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.queues.view",{url:"/view/:id",templateUrl:"app/channels/mail/queue/view/view.html", -controller:"MailQueueViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.mail.queues.view.settings",{url:"/settings",templateUrl:"app/channels/mail/queue/view/view.settings.html"}).state("main.channels.mail.queues.view.agents",{url:"/agents",templateUrl:"app/channels/mail/queue/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.realtime",{url:"/realtime",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewAgentCtrl",["$scope","$log","$uibModal","$translate","socket","xAlert","Agent","Pause","Action","MailQueue","usSpinnerService","$q","uiGridConstants",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){return k.spin("spinner-grid"),g.get(s).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.data=[],b.rows.forEach(function(a){p(a)})})["catch"](function(a){f.show(a.message,"danger")})["finally"](function(){k.stop("spinner-grid")})}function o(){e.socket.on("agent:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.id,isAgent:!0});if(c){var d=a.gridOptions.data.indexOf(c);a.gridOptions.data[d].online=b.online,a.gridOptions.data[d].lastLoginAt=b.lastLoginAt,a.gridOptions.data[d].pause=b.mailPause,a.gridOptions.data[d].pauseType=b.pauseType,a.gridOptions.data[d].lastPauseAt=b.lastPauseAt,a.gridOptions.data[d].ipaddr=b.ipaddr,a.gridOptions.data[d].port=b.port,a.gridOptions.data[d].fullcontact=b.fullcontact,a.gridOptions.data[d].useragent=b.useragent,a.gridOptions.data[d].lastms=b.lastms,a.gridOptions.data[d].internal=b.internal,_.map(a.gridOptions.data,function(a){a.isAgent||a.agentId!==b.id||(a.online=b.online)})}}),e.socket.on("agent:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.id})}),e.socket.on("user_has_mail_queue:save",function(b){console.log("new queue",b);var c=_.find(a.gridOptions.data,{agentId:b.UserId,isAgent:!0}),d=a.gridOptions.data.indexOf(c);a.gridOptions.data.splice(d+1,0,{isAgent:!1,agentId:b.UserId,queue:b.queue,queueId:b.MailQueueId,agent:b.membername,online:c.online})}),e.socket.on("user_has_mail_queue:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.UserId,queueId:b.MailQueueId})})}function p(b){a.gridOptions.data.push({isAgent:!0,agentId:b.id,agent:b.name,online:b.online,lastLoginAt:b.lastLoginAt,lastPauseAt:b.lastPauseAt,pause:b.mailPause,pauseType:b.pauseType,ipaddr:b.ipaddr,port:b.port,fullcontact:b.fullcontact,useragent:b.useragent,lastms:b.lastms,internal:b.internal,$$treeLevel:0}),b.MailQueues.forEach(function(c){a.gridOptions.data.push({isAgent:!1,agentId:b.id,queue:c.name,queueId:c.id,agent:b.name,online:b.online})})}function q(){return h.get().$promise.then(function(b){a.pauses=b.rows,e.syncUpdates("pause",a.pauses)})["catch"](function(a){f.show(a.message,"danger")})}function r(){return j.get().$promise.then(function(b){a.mailQueues=b.rows,e.syncUpdates("mail_queue",a.mailQueues)})["catch"](function(a){f.show(a.message,"danger")})}a.mailQueues=[];var s={offset:0,limit:10};a.moment=moment,a.initAgents=function(){a.gridOptions={enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,showTreeExpandNoChildren:!0,columnDefs:[{name:"name",displayName:"APPLICATION_AGENT",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.agent}} <{{row.entity.internal}}>
'},{name:"online",displayName:"APPLICATION_ONLINE",width:150,headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
({{hhours}}:{{mminutes}}:{{sseconds}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"ONLINE"},{value:"false",label:"OFFLINE"}]}},{name:"mailPause",width:300,displayName:"APPLICATION_PAUSE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{hhours}}:{{mminutes}}:{{sseconds}}({{row.entity.pauseType}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"PAUSED"},{value:"false",label:"NOT PAUSED"}]},enableSorting:!1,enableColumnMenu:!1},{name:"queue",displayName:"APPLICATION_QUEUE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",displayName:"",width:170,cellClass:"text-center ui-grid-vcenter",cellTemplate:'
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1}],data:[],gridMenuTitleFilter:function(a){var b=l.defer();return b.resolve(d.instant(a)),b.promise},onRegisterApi:function(b){a.gridApi=b,a.gridApi.grid.registerDataChangeCallback(function(){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length)}),a.gridApi.treeBase.on.rowExpanded(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length+b.treeNode.children.length)}),a.gridApi.treeBase.on.rowCollapsed(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length-b.treeNode.children.length)}),a.gridApi.core.on.sortChanged(a,function(a,b){0===b.length?s.order=null:s.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),n()}),a.gridApi.pagination.on.paginationChanged(a,function(a,b){s.offset=(a-1)*b,s.limit=b,n()}),a.gridApi.core.on.filterChanged(a,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?s[a.name]=a.filters[0].term:delete s[a.name]}),n()})}},n(),q(),r(),o()};var t=function(a){var b=a?30*a+130:270;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px"),angular.element(document.getElementsByClassName("ui-grid-viewport")).css("height",30*a+"px")};a.$on("$destroy",function(){e.unsyncUpdates("agent"),e.unsyncUpdates("user_has_mail_queue")}),a.pause=function(a,b,c){return i.save({name:b,agent:a,type:c||"DEFAULT PAUSE",data4:c||"DEFAULT PAUSE",channel:"mail"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.joinQueue=function(e){var g=c.open({animation:!0,templateUrl:"app/channels/mail/realtime/view/agent/queue.modal.add.html",controller:"MailRealtimeViewAgentQueueModalCtrl",resolve:{queues:function(){return _.reject(a.mailQueues,function(b){return _.find(a.gridOptions.data,{queue:b.name,isAgent:!1,agentId:e})?!0:!1})}}});g.result.then(function(b){return i.save({name:"QueueAdd",agent:e,queues:_.filter(a.mailQueues,function(a){return _.includes(b.queues,a.id)}),channel:"mail",data1:e,data3:b.queues.join(","),data4:"mail"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},function(){b.info("Modal dismissed at: "+new Date)})},a.leaveQueue=function(a,b){return i.save({name:"QueueRemove",agent:a,queueId:b,channel:"mail",data1:a,data3:b,data4:"mail"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.showInfo=function(a){c.open({animation:!0,templateUrl:"app/channels/mail/realtime/view/agent/agent.modal.info.html",controller:"MailRealtimeViewAgentInfoModalCtrl",resolve:{agent:a}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.realtime.view.agents",{url:"/agents",templateUrl:"app/channels/mail/realtime/view/agent/agent.html",controller:"MailRealtimeViewAgentCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewAgentInfoModalCtrl",["$scope","$uibModalInstance","$http","agent",function(a,b,c,d){a.agent=d,a.close=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewAgentQueueModalCtrl",["$scope","$uibModalInstance","$http","queues",function(a,b,c,d){a.queues=d,a.item={},a.save=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewQueueCtrl",["$scope","$http","socket","MailQueue","Agent",function(a,b,c,d,e){a.initQueues=function(){a.gridOptions={enableSorting:!1,enableFiltering:!0,enableHorizontalScrollbar:0,enableVerticalScrollbar:0,showTreeExpandNoChildren:!1,columnDefs:[{name:"queueName",displayName:"Queue"},{name:"fullname",displayName:"Agent",cellClass:"text-center"},{name:"online",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'},{name:"chatPause",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
"},{name:"pauseType",cellClass:"text-center",cellTemplate:'{{row.entity.pauseType}}'},{name:"lastLoginAt",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'}],onRegisterApi:function(b){a.gridApi=b,a.gridApi.treeBase.on.rowExpanded(a,function(b){var c=_.findIndex(a.gridOptions.data,{$$hashKey:b.entity.$$hashKey});b.entity.Users&&b.entity.Users.forEach(function(b){_.find(a.gridOptions.data,{name:b.name})||a.gridOptions.data.splice(c+1,0,b)})})}},d.get(function(b){a.gridOptions.data=[],b.rows.forEach(function(b){b.$$treeLevel=0,b.queueName=b.name,a.gridOptions.data.push(b),b.Users&&b.Users.forEach(function(b){b.agentName=b.name,a.gridOptions.data.push(b)})}),c.socket.on("agent:save",function(b){var c=_.filter(a.gridOptions.data,{agentName:b.name});c.forEach(function(a){a.online=b.online,a.lastLoginAt=b.lastLoginAt})}),c.socket.on("mail_queue:save",function(b){b.$$treeLevel=0,b.queueName=b.name,a.gridOptions.data.push(b)}),c.socket.on("mail_queue:remove",function(b){_.remov(a.gridOptions.data,{queueName:b.name})}),c.socket.on("user_has_mail_queue:save",function(b){var c=_.findIndex(a.gridOptions.data,function(a){return a.queueName&&a.id===b.MailQueueId});e.get({id:b.UserId}).$promise.then(function(b){a.gridOptions.data.splice(c+1,0,{id:b.id,name:b.name,fullname:b.fullname,agentName:b.name,online:b.online,lastLoginAt:b.lastLoginAt})})["catch"](function(a){console.error(a)})}),c.socket.on("user_has_mail_queue:remove",function(b){for(var c=_.findIndex(a.gridOptions.data,function(a){return a.queueName&&a.id===b.MailQueueId}),d=c+1;dApril 1, 2014',sort:{direction:d.DESC,priority:1}},{name:"leaveAt",displayName:"leaveAt",cellClass:"text-center",cellTemplate:''},{name:"unmanagedAt",displayName:"unmanangedAt",cellClass:"text-center",cellTemplate:''}],data:[]},b.get("/api/report/mail/sessions").success(function(b){a.gridOptions.data=b.rows,c.socket.on("report_mail_session:save",function(b){var c=_.find(a.gridOptions.data,{id:b.id}),d=a.gridOptions.data.indexOf(c);c?_.merge(a.gridOptions.data[d],b):a.gridOptions.data.unshift(b)})}).error(function(a){console.error(a)})},a.$on("$destroy",function(){c.unsyncUpdates("report_mail:save"),c.unsyncUpdates("report_mail:update")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.realtime.view.sessions",{url:"/sessions",templateUrl:"app/channels/mail/realtime/view/session/session.html",controller:"MailRealtimeViewSessionCtrl"})}]),angular.module("xCallyShuttleApp").controller("MailRealtimeViewCtrl",["$scope","$state",function(a,b){a.agents=[{name:"Queues",link:"main.channels.mail.realtime.view.agents.queues"},{name:"Timeline",link:"main.channels.mail.realtime.view.agents.timeline"}],a.sessions=[{name:"Sessions",link:"main.channels.mail.realtime.view.sessions"}],a.tree={queues:[{name:"Queues",link:"main.channels.mail.realtime.view.agents.queues"},{name:"Timeline",link:"main.channels.mail.realtime.view.agents.timeline"}],sessions:[{name:"Sessions",link:"main.channels.mail.realtime.view.sessions"}]}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.mail.realtime.view",{url:"/view",templateUrl:"app/channels/mail/realtime/view/view.html",controller:"MailRealtimeViewCtrl"})}]),angular.module("xCallyShuttleApp").factory("ReportCall",["$resource",function(a){return a("/api/report/calls/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("ChanSpy",["$resource",function(a){return a("/api/chanspy/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.chanspy",{url:"/chanspy",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ChanSpyListCtrl",["$scope","$uibModal","ChanSpy","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"chanspy.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/channels/voice/chanspy/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/channels/voice/chanspy/list/list.create.modal.html",controller:"ChanSpyListCreateCtrl"});c.result.then(function(b){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("ChanSpyListCreateCtrl",["$scope","$translate","$uibModalInstance","ChanSpy","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.options=[{name:"APPLICATION_CHANSPY_OPTION_b",value:"b"},{name:"APPLICATION_CHANSPY_OPTION_B",value:"B"},{name:"APPLICATION_CHANSPY_OPTION_E",value:"E"},{name:"APPLICATION_CHANSPY_OPTION_o",value:"o"},{name:"APPLICATION_CHANSPY_OPTION_q",value:"q"},{name:"APPLICATION_CHANSPY_OPTION_s",value:"s"},{name:"APPLICATION_CHANSPY_OPTION_S",value:"S"},{name:"APPLICATION_CHANSPY_OPTION_w",value:"w"},{name:"APPLICATION_CHANSPY_OPTION_W",value:"W"}],a.save=function(){return a.item.options=a.item.options.join(""),d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.chanspy.list",{url:"/list",templateUrl:"app/channels/voice/chanspy/list/list.html",controller:"ChanSpyListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ChanSpyViewCtrl",["$scope","$translate","$stateParams","xAlert","ChanSpy",function(a,b,c,d,e){a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.options=[{name:"APPLICATION_CHANSPY_OPTION_b",value:"b"},{name:"APPLICATION_CHANSPY_OPTION_B",value:"B"},{name:"APPLICATION_CHANSPY_OPTION_E",value:"E"},{name:"APPLICATION_CHANSPY_OPTION_o",value:"o"},{name:"APPLICATION_CHANSPY_OPTION_q",value:"q"},{name:"APPLICATION_CHANSPY_OPTION_s",value:"s"},{name:"APPLICATION_CHANSPY_OPTION_S",value:"S"},{name:"APPLICATION_CHANSPY_OPTION_w",value:"w"},{name:"APPLICATION_CHANSPY_OPTION_W",value:"W"}],a.getChanSpy=function(){return e.get({id:c.id}).$promise.then(function(b){b.options=b.options.split(""),a.chanspy=b})["catch"](function(a){d.show(a.data.message,"danger")})},a.updateChanSpy=function(){var f=angular.copy(a.chanspy);return f.options=f.options.join(""),e.update({id:c.id},f).$promise.then(function(){d.show(b.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){d.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.chanspy.view",{url:"/view/:id",templateUrl:"app/channels/voice/chanspy/view/view.html",controller:"ChanSpyViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.chanspy.view.settings",{url:"/settings",templateUrl:"app/channels/voice/chanspy/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("VoiceContext",["$resource",function(a){return a("/api/voice/contexts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.contexts",{url:"/contexts",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceContextListCtrl",["$scope","VoiceContext","gridOptions","$uibModal","xAlert","$translate",function(a,b,c,d,e,f){a.initView=function(){var d={exporterCsvFilename:"voice_contexts.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:170,buttons:[{"class":"{{row.entity.defaultEntry ? 'blue-hoki disabled' : 'blue-hoki'}}",href:"/channels/voice/contexts/view/{{row.entity.id}}/settings",name:"settings"},{"class":"{{row.entity.defaultEntry ? 'red-sunglo disabled' : 'red-sunglo'}}",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){var c=d.open({animation:!0,templateUrl:"app/channels/voice/context/list/create.modal.html",controller:["$scope","$uibModalInstance",function(a,b){a.form={},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]});c.result.then(function(c){return b.save(c).$promise.then(function(){a.gridOptions.getPage(),e.show(f.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){e.show(a.data.message,"danger")})})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.contexts.list",{url:"/list",templateUrl:"app/channels/voice/context/list/list.html",controller:"VoiceContextListCtrl"})}]),angular.module("xCallyShuttleApp").controller("VoiceContextViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location",function(a,b,c,d,e,f){a.getContext=function(){b.get("/api/voice/contexts/"+e.id).success(function(b){a.context=b}).error(function(a){console.error(a),f.path("/voice/contexts/list")})},a.updateVoiceContext=function(){var f=angular.copy(a.context);b.put("/api/voice/contexts/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(b){c.show(d.instant(b.message),"danger"),a.context=f})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.contexts.view",{url:"/view/:id",templateUrl:"app/channels/voice/context/view/view.html",controller:"VoiceContextViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.contexts.view.settings",{url:"/settings",templateUrl:"app/channels/voice/context/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("VoiceMohListCtrl",["$scope","gridOptions","VoiceMoh","$uibModal","xAlert","$translate",function(a,b,c,d,e,f){a.initView=function(){var d={exporterCsvFilename:"voice_mohs.csv",columnDefs:[{name:"name"},{name:"directory"},{name:"sort"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/voice/mohs/view/{{row.entity.id}}/settings",name:"settings"},{"class":"{{row.entity.defaultEntry ? 'red-sunglo disabled' : 'red-sunglo'}}",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=b.gridOptions(c,d,a)},a.createItem=function(){var b=d.open({animation:!0,templateUrl:"app/channels/voice/moh/list/create.modal.html",controller:["$scope","$uibModalInstance",function(a,b){a.form={},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]});b.result.then(function(b){return c.save(b).$promise.then(function(){a.gridOptions.getPage(),e.show(f.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.mohs.list",{url:"/list",templateUrl:"app/channels/voice/moh/list/list.html",controller:"VoiceMohListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("VoiceMoh",["$resource",function(a){return a("/api/voice/musiconholds/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.mohs",{url:"/mohs",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceMohViewCtrl",["$scope","$http","xAlert","$translate","VoiceMoh","$stateParams","socket","Modal","$sce","$location","Sound",function(a,b,c,d,e,f,g,h,i,j,k){a.$translate=d,a.audioSources={},a.sortOptions=[{value:"random",name:"APPLICATION_RANDOM"},{value:"alpha",name:"APPLICATION_ALPHABETICAL"}],a.getMoh=function(){return e.get({id:f.id}).$promise.then(function(b){delete b.stamp,a.moh=b})["catch"](function(a){c.show(a.message,"danger")})},a.updateVoiceMoh=function(){return console.log("update"),e.update({id:f.id},a.moh).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){c.show(a.message,"danger")})},a.addMohs=function(){return e.save({id:f.id,controller:"files"},a.item).$promise.then(function(){j.path("/channels/voice/mohs/view/"+f.id+"/audios")})["catch"](function(a){c.show(a.message,"danger")})},a.getAudioFiles=function(){return e.get({id:f.id,controller:"files"}).$promise.then(function(b){a.audioFiles=b.files,a.mohPath=b.path,a.audioFiles.forEach(function(a){l(a)})})["catch"](function(a){c.show(a.message,"danger")})},a.getSecureSrc=function(a){return i.trustAsResourceUrl(a)},a.getSounds=function(){return a.item={sounds:[]},k.get().$promise.then(function(b){a.soundList=b.rows})["catch"](function(a){c.show(a.message,"danger")})};var l=function(c){b.get("/api/voice/musiconholds/stream",{params:{path:encodeURI(a.mohPath+"/"+c)}}).success(function(b){a.audioSources[c]="data:audio/ogg;base64,"+b}).error(function(a){console.error(a)})};a.deleteItem=h.confirm["delete"](function(e){b["delete"]("/api/voice/musiconholds/"+f.id+"/files",{params:{filename:e}}).success(function(){_.remove(a.audioFiles,function(a){return a===e}),c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(a){c.show(a.message,"danger")})})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.mohs.view",{url:"/view/:id",templateUrl:"app/channels/voice/moh/view/view.html",controller:"VoiceMohViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.mohs.view.settings",{url:"/settings",templateUrl:"app/channels/voice/moh/view/view.settings.html"}).state("main.channels.voice.mohs.view.audios",{url:"/audios",templateUrl:"app/channels/voice/moh/view/view.audios.html",cache:!1}).state("main.channels.voice.mohs.view.add",{url:"/add",templateUrl:"app/channels/voice/moh/view/view.addFiles.html",cache:!1})}]),angular.module("xCallyShuttleApp").controller("VoiceQueueListCtrl",["$scope","$rootScope","VoiceQueue","gridOptions","$uibModal",function(a,b,c,d,e){a.initView=function(){var b={exporterCsvFilename:"voice_queues.csv",primaryKey:"name",columnDefs:[{name:"name"},{name:"strategy"},{name:"description"},{name:"action",width:200,buttons:[{"class":"blue-hoki",href:"/channels/voice/queues/view/{{row.entity.name}}/settings",name:"settings"},{"class":"green-meadow",href:"/channels/voice/queues/view/{{row.entity.name}}/agents",name:"agents"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.name)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var b=e.open({animation:!0,templateUrl:"app/channels/voice/queue/list/list.create.modal.html",controller:"VoiceQueueListCreateCtrl"});b.result.then(function(){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("VoiceQueueListCreateCtrl",["$scope","$uibModalInstance","$translate","xAlert","VoiceQueue",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return e.save(a.item).$promise.then(function(a){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),b.close(a)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.queues.list",{url:"/list",templateUrl:"app/channels/voice/queue/list/list.html",controller:"VoiceQueueListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.queues",{url:"/queues",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("ReportQueue",["$resource",function(a){return a("/api/report/queues/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("VoiceQueueViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","socket","$location","VoiceQueue","VoiceContext","Team",function(a,b,c,d,e,f,g,h,i,j){a.penalty=0,a.binaryChoices=[{name:"Yes",value:1},{name:"No",value:0}],a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.monitorFormats=[{name:"wav",value:"wav"},{name:"gsm",value:"gsm"},{name:"Inactive",value:""}],a.queueAnnounces=[{display_name:"Default",value:null},{display_name:"Disabled",value:""}];var k=function(){return{select:function(b){return h.save({id:a.queue.name,controller:"agents"},{agents:b,penalty:a.queue.penalty}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})},deselect:function(b){return h["delete"]({id:a.queue.name,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})}}};a.getQueue=function(){return h.get({id:e.id}).$promise.then(function(b){b.joinempty=""===b.joinempty?[]:b.joinempty.split(","),b.leavewhenempty=""===b.leavewhenempty?[]:b.leavewhenempty.split(","),b.periodic_announce=""===b.periodic_announce?[]:b.periodic_announce.split(","),b.penalty=0,a.queue=b})["catch"](function(a){g.path("/channels/voice/queues/list")})},a.updateVoiceQueue=function(){var b=angular.copy(a.queue);return b.joinempty=b.joinempty.join(","),b.leavewhenempty=b.leavewhenempty.join(","), -b.periodic_announce=b.periodic_announce.join(","),b.context||(b.context=null),h.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(d.instant(a.data.message),"danger")})},a.getTeams=function(){return j.get().$promise.then(function(b){return a.teams=b.rows,h.query({id:e.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindQueue(a.teams,_.map(b,function(a){return{id:a.id,penalty:a.UserHasVoiceQueue.penalty}}),k)})["catch"](function(a){console.error(a)})},a.getContexts=function(){return i.get().$promise.then(function(b){a.voiceContexts=b.rows})["catch"](function(a){c.show(d.instant(data.message),"danger")})},a.getMohs=function(){b.get("/api/voice/musiconholds").success(function(b){a.voiceMohs=b.rows,f.syncUpdates("voice_musiconhold",a.voiceMohs)}).error(function(a){c.show(a.message,"danger")})},a.getSounds=function(){b.get("/api/sounds").success(function(b){a.queueAnnounces=a.queueAnnounces.concat(b),a.periodicAnnounces=angular.copy(b.rows),b.rows.unshift({display_name:"None",converted_path:null,value:""}),a.sounds=b.rows,f.syncUpdates("sound",a.sounds)}).error(function(a){console.error(a)})},a.returnAnnouncePath=function(a){return a.converted_path?a.converted_path+"/"+a.save_name:null===a.value?null:a.value}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.queues.view",{url:"/view/:id",templateUrl:"app/channels/voice/queue/view/view.html",controller:"VoiceQueueViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.queues.view.settings",{url:"/settings",templateUrl:"app/channels/voice/queue/view/view.settings.html"}).state("main.channels.voice.queues.view.agents",{url:"/agents",templateUrl:"app/channels/voice/queue/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}})}]),angular.module("xCallyShuttleApp").factory("VoiceQueue",["$resource",function(a){return a("/api/voice/queues/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.realtime",{url:"/realtime",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewAgentCtrl",["$scope","$log","$uibModal","$translate","socket","xAlert","Agent","Pause","Action","VoiceQueue","usSpinnerService","$q","uiGridConstants",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){return k.spin("spinner-grid"),g.get(s).$promise.then(function(b){a.gridOptions.totalItems=b.count,a.gridOptions.data=[],b.rows.forEach(function(a){p(a)})})["catch"](function(a){f.show(a.message,"danger")})["finally"](function(){k.stop("spinner-grid")})}function o(){e.socket.on("agent:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.id,isAgent:!0});if(c){var d=a.gridOptions.data.indexOf(c);a.gridOptions.data[d].online=b.online,a.gridOptions.data[d].lastLoginAt=b.lastLoginAt,a.gridOptions.data[d].pause=b.voicePause,a.gridOptions.data[d].pauseType=b.pauseType,a.gridOptions.data[d].lastPauseAt=b.lastPauseAt,a.gridOptions.data[d].status=b.status,a.gridOptions.data[d].statusAt=b.statusAt,a.gridOptions.data[d].queueStatus=b.queueStatus,a.gridOptions.data[d].queueStatusAt=b.queueStatusAt,a.gridOptions.data[d].lastQueue=b.lastQueue,a.gridOptions.data[d].ipaddr=b.ipaddr,a.gridOptions.data[d].port=b.port,a.gridOptions.data[d].fullcontact=b.fullcontact,a.gridOptions.data[d].useragent=b.useragent,a.gridOptions.data[d].lastms=b.lastms,a.gridOptions.data[d].internal=b.internal,_.map(a.gridOptions.data,function(a){a.isAgent||a.agentId!==b.id||(a.online=b.online)})}}),e.socket.on("agent:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.id})}),e.socket.on("user_has_voice_queue:save",function(b){var c=_.find(a.gridOptions.data,{agentId:b.UserId,queue:b.queue});if(!c&&b.logged){var d=_.find(a.gridOptions.data,{agentId:b.UserId,isAgent:!0}),e=a.gridOptions.data.indexOf(d);a.gridOptions.data.splice(e+1,0,{isAgent:!1,agentId:b.UserId,queue:b.queue,agent:b.membername,callstaken:b.callstaken?b.callstaken:0,online:d.online})}else c&&!b.logged?_.remove(a.gridOptions.data,{agentId:b.UserId,queue:b.queue}):c&&b.logged&&(c.callstaken=b.callstaken?b.callstaken:0)}),e.socket.on("user_has_voice_queue:remove",function(b){_.remove(a.gridOptions.data,{agentId:b.UserId,queue:b.queue})})}function p(b){a.gridOptions.data.push({isAgent:!0,agentId:b.id,agent:b.name,online:b.online,lastLoginAt:b.lastLoginAt,lastPauseAt:b.lastPauseAt,pause:b.voicePause,pauseType:b.pauseType,status:b.status||"UNKNOWN",statusAt:b.statusAt,queueStatus:b.queueStatus||"READY",queueStatusAt:b.queueStatusAt,lastQueue:b.lastQueue,ipaddr:b.ipaddr,port:b.port,fullcontact:b.fullcontact,useragent:b.useragent,lastms:b.lastms,internal:b.internal,$$treeLevel:0}),b.VoiceQueues.forEach(function(c){c.UserHasVoiceQueue.logged&&a.gridOptions.data.push({isAgent:!1,agentId:b.id,queue:c.name,agent:b.name,callstaken:c.UserHasVoiceQueue.callstaken?c.UserHasVoiceQueue.callstaken:0,online:b.online})})}function q(){return h.get().$promise.then(function(b){a.pauses=b.rows,e.syncUpdates("pause",a.pauses)})["catch"](function(a){f.show(a.message,"danger")})}function r(){return j.get().$promise.then(function(b){a.voiceQueues=b.rows,e.syncUpdates("voice_queue",a.voiceQueues)})["catch"](function(a){f.show(a.message,"danger")})}a.voiceQueues=[];var s={offset:0,limit:10};a.moment=moment,a.initAgents=function(){a.gridOptions={enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,showTreeExpandNoChildren:!0,columnDefs:[{name:"name",displayName:"APPLICATION_AGENT",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.agent}} <{{row.entity.internal}}>
'},{name:"online",displayName:"APPLICATION_ONLINE",width:150,headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
({{hhours}}:{{mminutes}}:{{sseconds}})
',filter:{type:m.filter.SELECT,selectOptions:[{value:"true",label:"ONLINE"},{value:"false",label:"OFFLINE"}]}},{name:"status",displayName:"APPLICATION_PHONE_STATUS",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:"
{{'APPLICATION_'+row.entity.status | translate}} ({{hhours}}:{{mminutes}}:{{sseconds}})
",filter:{type:m.filter.SELECT,selectOptions:[{value:"UNKNOWN",label:d.instant("APPLICATION_UNKNOWN")},{value:"NOT_INUSE",label:d.instant("APPLICATION_NOT_INUSE")},{value:"INUSE",label:d.instant("APPLICATION_INUSE")},{value:"BUSY",label:d.instant("APPLICATION_BUSY")},{value:"INVALID",label:d.instant("APPLICATION_INVALID")},{value:"UNAVAILABLE",label:d.instant("APPLICATION_UNAVAILABLE")},{value:"RINGING",label:d.instant("APPLICATION_RINGING")},{value:"RINGINUSE",label:d.instant("APPLICATION_RINGINUSE")},{value:"ONHOLD",label:d.instant("APPLICATION_ONHOLD")}]}},{name:"queueStatus",width:400,displayName:"APPLICATION_QUEUE_STATUS",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{\'APPLICATION_\'+row.entity.queueStatus.toUpperCase() | translate}} [{{row.entity.lastQueue}}] [{{row.entity.pauseType}}] [{{hhours}}:{{mminutes}}:{{sseconds}}]
',filter:{type:m.filter.SELECT,selectOptions:[{value:"paused",label:d.instant("APPLICATION_PAUSED")},{value:"connect",label:d.instant("APPLICATION_CONNECT")},{value:"complete",label:d.instant("APPLICATION_COMPLETE")},{value:"called",label:d.instant("APPLICATION_CALLED")}]},enableSorting:!1,enableColumnMenu:!1},{name:"queue",displayName:"APPLICATION_QUEUE",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"callstaken",displayName:"APPLICATION_CALLS_TAKEN",headerCellFilter:"translate",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
{{row.entity.callstaken}}
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1,width:100},{name:"action",displayName:"",width:170,cellClass:"text-center ui-grid-vcenter",cellTemplate:'
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1}],data:[],gridMenuTitleFilter:function(a){var b=l.defer();return b.resolve(d.instant(a)),b.promise},onRegisterApi:function(b){a.gridApi=b,a.gridApi.grid.registerDataChangeCallback(function(){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length)}),a.gridApi.treeBase.on.rowExpanded(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length+b.treeNode.children.length)}),a.gridApi.treeBase.on.rowCollapsed(a,function(b){t(a.gridApi.core.getVisibleRows(a.gridApi.grid).length-b.treeNode.children.length)}),a.gridApi.core.on.sortChanged(a,function(a,b){0===b.length?s.order=null:s.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),n()}),a.gridApi.pagination.on.paginationChanged(a,function(a,b){s.offset=(a-1)*b,s.limit=b,n()}),a.gridApi.core.on.filterChanged(a,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?s[a.name]=a.filters[0].term:delete s[a.name]}),n()})}},n(),q(),r(),o()};var t=function(a){var b=a?30*a+130:270;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px"),angular.element(document.getElementsByClassName("ui-grid-viewport")).css("height",30*a+"px")};a.$on("$destroy",function(){e.unsyncUpdates("agent"),e.unsyncUpdates("user_has_voice_queue")}),a.pause=function(a,b,c){return i.save({name:b,agent:a,type:c||"DEFAULT PAUSE",data4:c||"DEFAULT PAUSE",channel:"voice"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(d.instant(a.message||a.data.message||a.translatedMessage||a.data.translatedMessage),"danger")})},a.joinQueue=function(e){var g=c.open({animation:!0,templateUrl:"app/channels/voice/realtime/view/agent/queue.modal.add.html",controller:"VoiceRealtimeViewAgentQueueModalCtrl",resolve:{queues:function(){return _.reject(a.voiceQueues,function(b){return _.find(a.gridOptions.data,{queue:b.name,isAgent:!1,agentId:e})?!0:!1})}}});g.result.then(function(a){return i.save({name:"QueueAdd",agent:e,queues:a.queues,channel:"voice",data1:e,data3:a.queues.join(","),data4:"voice"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},function(){b.info("Modal dismissed at: "+new Date)})},a.leaveQueue=function(a,b){return i.save({name:"QueueRemove",agent:a,queue:b,channel:"voice",data1:a,data3:b,data4:"voice"}).$promise.then(function(){f.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.showInfo=function(a){c.open({animation:!0,templateUrl:"app/channels/voice/realtime/view/agent/agent.modal.info.html",controller:"VoiceRealtimeViewAgentInfoModalCtrl",resolve:{agent:a}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.realtime.view.agents",{url:"/agents",templateUrl:"app/channels/voice/realtime/view/agent/agent.html",controller:"VoiceRealtimeViewAgentCtrl"})}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewAgentInfoModalCtrl",["$scope","$uibModalInstance","$http","agent",function(a,b,c,d){a.agent=d,a.close=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewAgentQueueModalCtrl",["$scope","$uibModalInstance","$http","queues",function(a,b,c,d){a.queues=d,a.item={},a.save=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewAgentReportCtrl",["$scope","$http","socket",function(a,b,c){a.$on("$destroy",function(){c.unsyncUpdates("report_agent")}),a.conf={agentsByPage:{name:"10",value:10},labels:["fullname","name","email"]},a.agentsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.initReport=function(){a.agents=[],b.get("/api/report/agents").success(function(b){a.agents=b,c.syncUpdates("report_agent",a.agents)}).error(function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").filter("VoiceRealtimeViewAgentReportFilter",function(){return function(a){return new Date(1970,0,1).setSeconds(a)}}),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewQueueReportCtrl",["$scope","$http","socket",function(a,b,c){a.$on("$destroy",function(){c.unsyncUpdates("report_queue")}),a.conf={queuesByPage:{name:"10",value:10},labels:["fullname","name","email"]},a.queuesByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.initReport=function(){a.queues=[],b.get("/api/report/queues").success(function(b){console.log(b),a.queues=b,c.syncUpdates("report_queue",a.queues)}).error(function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").filter("VoiceRealtimeViewQueueReportFilter",function(){return function(a){return new Date(1970,0,1).setSeconds(a)}}),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewQueuePauseModalCtrl",["$scope","$uibModalInstance","items","data",function(a,b,c,d){a.items=c,a.data=d,console.log(d),a.selected={item:a.items[0],queue:_.isArray(d)?a.data[0].queue:a.data.queue,membername:_.isArray(d)?a.data[0].membername:a.data.membername,"interface":_.isArray(d)?a.data[0]["interface"]:a.data["interface"]},a.ok=function(c,e){var f;_.isArray(d)?(f=[],d.forEach(function(b){f.push({action:"QueuePause",queue:b.queue,membername:b.membername,"interface":b["interface"],paused:c,reason:a.selected.item})})):f={action:"QueuePause",queue:a.selected.queue,membername:a.selected.membername,"interface":a.selected["interface"],paused:c,reason:a.selected.item},b.close(f)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewQueueCtrl",["$scope","$http","$log","$uibModal","$translate","socket","xAlert",function(a,b,c,d,e,f,g){a.conf={agentsByPage:{name:"10",value:10},labels:["fullname","name","email"]},a.agentsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.$on("$destroy",function(){f.unsyncUpdates("user_has_voice_queue")}),a.groups=[],a.pauses=["pausa1","pausa2","pausa3"],a.pause=function(f,h){var i=d.open({animation:!0,size:f,templateUrl:"app/channels/voice/realtime/view/queue/pause.modal.html",controller:"VoiceRealtimeViewQueuePauseModalCtrl",resolve:{items:function(){return a.pauses},data:function(){return h}}});i.result.then(function(a){_.isArray(a)?a.forEach(function(a){b.post("/api/ami",a).then(function(a){console.log(a),g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.log(a),g.show(a.data.message,"danger")})}):b.post("/api/ami",a).then(function(a){console.log(a),g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.log(a),g.show(a.data.message,"danger")})},function(){c.info("Modal dismissed at: "+new Date)})},a.add=function(f,h){var i=d.open({animation:!0,size:f,templateUrl:"app/channels/voice/realtime/view/queue/queue.modal.add.html",controller:"VoiceRealtimeViewQueueQueueModalCtrl",resolve:{pauses:function(){return a.pauses},data:function(){return h}}});i.result.then(function(a){console.log("action",a),b.post("/api/voice/user_has_queues",a).then(function(){a.login?b.post("/api/ami",a).then(function(){g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")}):g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.message,"danger")}),console.log(a)},function(){c.info("Modal dismissed at: "+new Date)})},a.remove=function(a,f){var h=d.open({animation:!0,size:a,templateUrl:"app/channels/voice/realtime/view/queue/queue.modal.remove.html",controller:"VoiceRealtimeViewQueueQueueModalCtrl",resolve:{pauses:function(){return null},data:function(){return f}}});h.result.then(function(a){_.isArray(a)?a.forEach(function(a){b.post("/api/ami",a).then(function(){a.logout?b.put("/api/voice/queues/"+a.queue+"/agents",{agents:[a.UserId]}).then(function(){g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")}):g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")})}):b.post("/api/ami",a).then(function(){a.logout?b.put("/api/voice/queues/"+a.queue+"/agents",{agents:[a.UserId]}).then(function(){g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")}):g.show(e.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.data.message,"danger")})},function(){c.info("Modal dismissed at: "+new Date)})},a.initQueues=function(){b.get("/api/voice/user_has_queues").success(function(b){a.queues=b,a.groups=_.map(_.groupBy(a.queues,"queue"),function(a,b){return{queue:b,agents:a}}),console.log("ok"),f.socket.on("user_has_voice_queue:save",function(b){console.log("item",b);var c=_.find(a.groups,{queue:b.queue}),d=a.groups.indexOf(c);if(c){var e=_.find(c.agents,{membername:b.membername});e?_.merge(e,b):a.groups[d].agents.push(b)}else{var f={queue:b.queue,agents:[b]};a.groups.unshift(f)}}),f.socket.on("user_has_voice_queue:remove",function(b){var c=_.find(a.groups,{queue:b.queue});_.remove(c.agents,{membername:b.membername}),c.agents.length||_.remove(a.groups,{queue:b.queue})}),f.socket.on("report_agent:save",function(b){var c=_.find(a.groups,{queue:b.queue}),d=a.groups.indexOf(c);if(c){var e=_.find(c.agents,{membername:b.membername});e?_.merge(e,b):a.groups[d].agents.push(b)}else{var f={queue:b.queue,agents:[b]};a.groups.unshift(f)}})}).error(function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewQueueQueueModalCtrl",["$scope","$uibModalInstance","$http","pauses","data",function(a,b,c,d,e){a.initAdd=function(){a.data=e,a.pauses=d,a.selected={penalty:0,paused:!1,reason:a.pauses[0]},a.$watch("selected.agent",function(b){b&&(a.selected.membername=b.name,a.selected["interface"]="SIP/"+b.name,a.selected.UserId=b.id)}),c.get("/api/agents",{params:{page:0,per_page:500}}).success(function(b){a.agents=_.reject(b.rows,function(b){return _.find(a.data,{membername:b.name})?!0:!1}),a.selected.queue=a.data[0]?a.data[0].queue:null}).error(function(a){console.error(a)})},a.initRemove=function(){a.data=e,console.log(e),_.isArray(e)?a.selected={queue:a.data[0].queue,logout:!1}:a.selected={membername:a.data.membername,"interface":a.data["interface"],queue:a.data.queue,logout:!1,UserId:a.data.UserId}},a.okAdd=function(){var c={action:"QueueAdd",queue:a.selected.queue,membername:a.selected.membername,"interface":a.selected["interface"],penalty:a.selected.penalty,paused:a.selected.paused,UserId:a.selected.UserId};c.paused&&(c.reason=a.selected.reason),b.close(c)},a.okRemove=function(){var c;_.isArray(a.data)?(c=[],a.data.forEach(function(b){c.push({action:"QueueRemove",queue:b.queue,"interface":b["interface"],logout:a.selected.logout,UserId:b.UserId})})):c={action:"QueueRemove",queue:a.selected.queue,logout:a.selected.logout,"interface":a.selected["interface"],UserId:a.selected.UserId},b.close(c)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRealtimeViewCtrl",["$scope",function(a){a.agents=[{name:"View1",link:"main.channels.voice.realtime.view.agents"},{name:"View2",link:"main.channels.voice.realtime.view.areports"}],a.queues=[{name:"View1",link:"main.channels.voice.realtime.view.queues"},{name:"View2",link:"main.channels.voice.realtime.view.qreports"}]}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.realtime.view",{url:"/view",templateUrl:"app/channels/voice/realtime/view/view.html",controller:"VoiceRealtimeViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("VoiceRecordingListCtrl",["$scope","$translate","$sce","Recording","gridOptions","xAlert","uiGridConstants",function(a,b,c,d,e,f,g){a.Recording=d;a.updateRating=function(a,c){d.patch({id:a,rating:c}).$promise.then(function(){f.show(b.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(a.message,"danger")})},a.initView=function(){var b={exporterCsvFilename:"recordings.csv",rowHeight:30,columnDefs:[{name:"uniqueid"},{name:"calleridnum"},{name:"calleridname"},{name:"connectedlinenum"},{name:"connectedlinename"},{name:"rating",filter:{type:g.filter.SELECT,selectOptions:[{value:1,label:"1"},{value:2,label:"2"},{value:3,label:"3"},{value:4,label:"4"},{value:5,label:"5"}]},cellClass:"ui-grid-vcenter",width:"100",cellTemplate:'
'},{name:"audio",displayName:"",width:225,enableSorting:!1,enableFiltering:!1,buttons:[{directive:''}]},{name:"action",width:150,buttons:[{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.uniqueid, row.entity.uniqueid)"},{directive:''}]}]};a.gridOptions=e.gridOptions(d,b,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.recordings.list",{url:"/list",templateUrl:"app/channels/voice/recording/list/list.html",controller:"VoiceRecordingListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Recording",["$resource",function(a){return a("/api/voice/recordings/:id/:controller",{id:"@id"},{update:{method:"PUT"},patch:{method:"PATCH"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.recordings",{url:"/recordings",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.inbound",{url:"/inbound",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInboundListCreateCtrl",["$scope","$uibModalInstance","Route","application","xAlert","$location","$translate",function(a,b,c,d,e,f,g){a.$application=d.application,a.forms={route:void 0},a.item={type:"inbound",appdata:"Inbound Call",context:"from-voip-provider"},a.ok=function(){return a.item.exten=a.$application.checkUnderscore(a.item.exten),c.save(a.item).$promise.then(function(a){b.close(a),f.path("/channels/voice/routes/inbound/view/"+a.id+"/applications")})["catch"](function(a){console.log(a),e.show(g.instant(a.data.translatedMessage),"danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInboundListCtrl",["$scope","$http","socket","$translate","$rootScope","xAlert","Modal","stResource","gridOptions","Route","$uibModal","$location","$log",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.initView=function(){var b={exporterCsvFilename:"InboundRoutes.csv",columnDefs:[{name:"exten",displayName:"APPLICATION_PHONE_NUMBER"},{name:"description"},{name:"applications",cellClass:"ui-grid-vcenter",cellTemplate:'
{{app.app}}({{app.appdata[0]}}), ...
{{\'MESSAGE_NO_AVAILABLE_APPLICATIONS\' | translate}}
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",width:170,buttons:[{"class":"blue-hoki",href:"/channels/voice/routes/inbound/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.exten, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(j,b,a,{type:"inbound"})},a.create=function(){k.open({animation:!0,templateUrl:"app/channels/voice/route/inbound/list/create.modal.html",controller:"VoiceRouteInboundListCreateCtrl"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.inbound.list",{url:"/list",templateUrl:"app/channels/voice/route/inbound/list/list.html",controller:"VoiceRouteInboundListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInboundViewCtrl",["$scope","$translate","$stateParams","socket","$location","WizardHandler","Modal","xAlert","application","interval","Route","VoiceQueue","Sound","SquareProject","VoiceContext","Interval","VoiceMail",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q){function r(b){var c,d;if("always"===b.intType)c=null,d="*,*,*,*";else if("list"===b.intType)d=b.IntervalId?_.find(a.Intervals,{id:b.IntervalId}).name:"*,*,*,*",c=b.IntervalId||null;else if("custom"===b.intType){c=null;var e,f,g,h;e=b.t_from&&b.t_to&&!b.alwaysTime?moment(b.t_from).format("HH:mm")+"-"+moment(b.t_to).format("HH:mm"):"*",b.wd_from&&"always"!==b.wd_from?(f=b.wd_from,b.wd_to&&"always"!==b.wd_to&&(f+="-"+b.wd_to)):f="*",b.md_from&&"always"!==b.md_from?(g=b.md_from,b.md_to&&"always"!==b.md_to&&(g+="-"+b.md_to)):g="*",b.m_from&&"always"!==b.m_from?(h=b.m_from,b.m_to&&"always"!==b.m_to&&(h+="-"+b.m_to)):h="*",d=e+","+f+","+g+","+h}void 0===a.selectedApp?(a.application.interval=d,a.application.IntervalId=c):(a.route.Applications[a.selectedApp].interval=d,a.route.Applications[a.selectedApp].IntervalId=c)}function s(){if(a.interval.intType=a.route.Applications[a.selectedApp].IntervalId?"list":"*,*,*,*"===a.route.Applications[a.selectedApp].interval?"always":"custom",a.interval.IntervalId=a.route.Applications[a.selectedApp].IntervalId,!a.route.Applications[a.selectedApp].IntervalId){var b,c=a.route.Applications[a.selectedApp].interval?a.route.Applications[a.selectedApp].interval.split(","):["*","*","*","*"];c.forEach(function(c,d){switch(d){case 0:"*"!==c?(b=c.split("-"),a.interval.t_from=moment(b[0],"HH:mm"),a.interval.t_to=moment(b[1],"HH:mm"),a.interval.alwaysTime=!1):(a.interval.t_from=moment(new Date),a.interval.t_to=moment(new Date),a.interval.alwaysTime=!0);break;case 1:"*"!==c?(b=c.split("-"),a.interval.wd_from=b[0],a.interval.wd_to=b[1]?b[1]:"always"):(a.interval.wd_from="always",a.interval.wd_to="always");break;case 2:"*"!==c?(b=c.split("-"),a.interval.md_from=b[0],a.interval.md_to=b[1]?b[1]:"always"):(a.interval.md_from="always",a.interval.md_to="always");break;case 3:"*"!==c?(b=c.split("-"),a.interval.m_from=b[0],a.interval.m_to=b[1]?b[1]:"always"):(a.interval.m_from="always",a.interval.m_to="always")}})}}a.$translate=b,a.$application=i.application,a.$interval=j.interval,a.gridOptions={rowTemplate:'
',columnDefs:[{name:"app",displayName:"APPLICATION_APPLICATION",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"appdata",displayName:"APPLICATION_ARGUMENTS",headerCellFilter:"translate",cellClass:"ui-grid-vcenter",cellTemplate:"
{{row.entity.appdata.join(',')}}
",enableSorting:!1,enableColumnMenu:!1},{name:"interval",displayName:"APPLICATION_TIME",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"action",enableSorting:!1,enableColumnMenu:!1,displayName:"APPLICATION_ACTION",headerCellFilter:"translate",width:125,cellTemplate:'{{\'APPLICATION_SETTINGS\' | translate}}{{\'APPLICATION_DELETE\' | translate}}'}],onRegisterApi:function(b){b.draggableRows.on.rowDropped(a,function(b,c){a.updateRoute()})}},a.initApplication=function(b){b&&(a.selectedApp=void 0),a.forms={settings:void 0,interval:void 0},a.application={},a.interval={intType:"always",t_from:moment(new Date),t_to:moment(new Date),wd_from:"always",wd_to:"always",md_from:"always",md_to:"always", -m_from:"always",m_to:"always",alwaysTime:!0},a.main={app:""}},a.$watch("interval",function(a){a&&r(a)},!0),a.updateSetAppdata=function(){a.application.variable&&a.application.value&&"Set"===a.main.app?a.application.appdata[0]=a.application.variable+"="+a.application.value:a.application.appdata[0]=null},a.updateSetAppdataSettings=function(){a.application.variable&&a.application.value&&"Set"===a.main.app?a.route.Applications[a.selectedApp].appdata[0]=a.application.variable+"="+a.application.value:a.application.appdata[0]=null},a.$watch("main.app",function(d){if(d){var e,f;switch(c.appId||(a.application={app:d,interval:a.application.interval||"*,*,*,*",appdata:[]}),d){case"Queue":e=l,f=m;break;case"Playback":e=m;break;case"AGI":e=n;break;case"Goto":e=o;break;case"Voicemail":e=q;break;default:e=null,f=null}if(e)return e.get().$promise.then(function(b){a.items=b.rows}).then(function(){return f?f.get().$promise:void 0}).then(function(b){b&&(a.items2=b.rows)})["catch"](function(a){h.show(b.instant(a.message),"danger")})}},!0),a.deselectAndRedirect=function(b){a.selectedApp=void 0,e.path(b)},a.getIntervals=function(){return p.get().$promise.then(function(b){a.Intervals=b.rows,d.syncUpdates("interval",a.Intervals)})["catch"](function(a){h.show(b.instant(a.message),"danger")})},a.getRoute=function(){return k.get({id:c.id}).$promise.then(function(b){a.route=b,a.gridOptions.data=b.Applications})["catch"](function(a){e.path("/channels/voice/routes/inbound/list")})},a.getApplication=function(){void 0===a.selectedApp&&e.path("/channels/voice/routes/inbound/list");var b=_.find(a.$application.applications,{value:a.route.Applications[a.selectedApp].app});if(a.main.app=b?b.value:"custom","Set"===a.main.app){var c=a.route.Applications[a.selectedApp].appdata[0].split("=");a.application.variable=c[0],a.application.value=c[1]}if(!b){var d=a.route.Applications[a.selectedApp].appdata.join(",");a.route.Applications[a.selectedApp].appdata=[d]}s()},a.openApplication=function(b){a.selectedApp=b,e.path("/channels/voice/routes/inbound/view/"+c.id+"/applications/settings")},a.updateRoute=function(d){return a.selectedApp=void 0,a.route.exten=a.$application.checkUnderscore(a.route.exten),k.update({id:a.route.id},a.route).$promise.then(function(a){h.show(b.instant("MESSAGE_WELL_DONE")+"!","success"),d&&e.path("/channels/voice/routes/inbound/view/"+c.id+"/"+d)})["catch"](function(a){console.log(a),h.show(b.instant(a.data.translatedMessage),"danger")})},a.getContexts=function(){return o.get().$promise.then(function(b){a.voiceContexts=b.rows,d.syncUpdates("voice_context",a.voiceContexts)})["catch"](function(a){h.show(b.instant(a.message),"danger")})},a.deleteApp=g.confirm["delete"](function(b){console.log(b),console.log(a.route.Applications[b]),a.route.Applications.splice(b,1)}),a.addApplication=function(){a.route.Applications.push(a.application),a.updateRoute("applications")},a.goNext=function(){f.wizard().next()},a.previous=function(){f.wizard().previous()},a.formValidation=function(a){return a},a.$on("destroy",function(){d.unsyncUpdates("voice_extension")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.inbound.view",{url:"/view/:id",templateUrl:"app/channels/voice/route/inbound/view/view.html",controller:"VoiceRouteInboundViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.routes.inbound.view.settings",{url:"/settings",templateUrl:"app/channels/voice/route/inbound/view/view.settings.html"}).state("main.channels.voice.routes.inbound.view.applications",{url:"/applications",templateUrl:"app/channels/voice/route/inbound/view/view.applications.html"}).state("main.channels.voice.routes.inbound.view.application",{url:"/application",templateUrl:"app/channels/voice/route/view.application.html"}).state("main.channels.voice.routes.inbound.view.applications.settings",{url:"/settings",templateUrl:"app/channels/voice/route/view.applicationSettings.html"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.internal",{url:"/internal",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInternalListCreateCtrl",["$scope","$uibModalInstance","Route","application","$location","$translate","xAlert",function(a,b,c,d,e,f,g){a.$application=d.application,a.forms={route:void 0},a.item={type:"internal",appdata:"Internal Call",context:"from-sip"},a.ok=function(){return a.item.exten=a.$application.checkUnderscore(a.item.exten),c.save(a.item).$promise.then(function(a){b.close(a),e.path("/channels/voice/routes/internal/view/"+a.id+"/applications")})["catch"](function(a){g.show(f.instant(a.data.translatedMessage),"danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInternalListCtrl",["$scope","$http","socket","$translate","$rootScope","xAlert","Modal","stResource","gridOptions","Route","$uibModal","$location","$log",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.initView=function(){var b={exporterCsvFilename:"InternalRoutes.csv",columnDefs:[{name:"exten",displayName:"APPLICATION_PHONE_NUMBER"},{name:"description"},{name:"applications",cellClass:"ui-grid-vcenter",cellTemplate:'
{{app.app}}({{app.appdata[0]}}),...
{{\'MESSAGE_NO_AVAILABLE_APPLICATIONS\' | translate}}
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",width:170,buttons:[{"class":"blue-hoki",href:"/channels/voice/routes/internal/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.exten, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(j,b,a,{type:"internal"})},a.create=function(){k.open({animation:!0,templateUrl:"app/channels/voice/route/internal/list/create.modal.html",controller:"VoiceRouteInternalListCreateCtrl"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.internal.list",{url:"/list",templateUrl:"app/channels/voice/route/internal/list/list.html",controller:"VoiceRouteInternalListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteInternalViewCtrl",["$scope","$translate","$stateParams","socket","$location","WizardHandler","Modal","xAlert","application","interval","Route","VoiceQueue","Sound","SquareProject","VoiceContext","Interval","VoiceMail",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q){function r(b){var c,d;if("always"===b.intType)c=null,d="*,*,*,*";else if("list"===b.intType)d=b.IntervalId?_.find(a.Intervals,{id:b.IntervalId}).name:"*,*,*,*",c=b.IntervalId||null;else if("custom"===b.intType){c=null;var e,f,g,h;e=b.t_from&&b.t_to&&!b.alwaysTime?moment(b.t_from).format("HH:mm")+"-"+moment(b.t_to).format("HH:mm"):"*",b.wd_from&&"always"!==b.wd_from?(f=b.wd_from,b.wd_to&&"always"!==b.wd_to&&(f+="-"+b.wd_to)):f="*",b.md_from&&"always"!==b.md_from?(g=b.md_from,b.md_to&&"always"!==b.md_to&&(g+="-"+b.md_to)):g="*",b.m_from&&"always"!==b.m_from?(h=b.m_from,b.m_to&&"always"!==b.m_to&&(h+="-"+b.m_to)):h="*",d=e+","+f+","+g+","+h}void 0===a.selectedApp?(a.application.interval=d,a.application.IntervalId=c):(a.route.Applications[a.selectedApp].interval=d,a.route.Applications[a.selectedApp].IntervalId=c)}function s(){if(a.interval.intType=a.route.Applications[a.selectedApp].IntervalId?"list":"*,*,*,*"===a.route.Applications[a.selectedApp].interval?"always":"custom",a.interval.IntervalId=a.route.Applications[a.selectedApp].IntervalId,!a.route.Applications[a.selectedApp].IntervalId){var b,c=a.route.Applications[a.selectedApp].interval?a.route.Applications[a.selectedApp].interval.split(","):["*","*","*","*"];c.forEach(function(c,d){switch(d){case 0:"*"!==c?(b=c.split("-"),a.interval.t_from=moment(b[0],"HH:mm"),a.interval.t_to=moment(b[1],"HH:mm"),a.interval.alwaysTime=!1):(a.interval.t_from=moment(new Date),a.interval.t_to=moment(new Date),a.interval.alwaysTime=!0);break;case 1:"*"!==c?(b=c.split("-"),a.interval.wd_from=b[0],a.interval.wd_to=b[1]?b[1]:"always"):(a.interval.wd_from="always",a.interval.wd_to="always");break;case 2:"*"!==c?(b=c.split("-"),a.interval.md_from=b[0],a.interval.md_to=b[1]?b[1]:"always"):(a.interval.md_from="always",a.interval.md_to="always");break;case 3:"*"!==c?(b=c.split("-"),a.interval.m_from=b[0],a.interval.m_to=b[1]?b[1]:"always"):(a.interval.m_from="always",a.interval.m_to="always")}})}}a.$translate=b,a.selectedApp=void 0,a.$application=i.application,a.$interval=j.interval,a.gridOptions={rowTemplate:'
',columnDefs:[{name:"app",displayName:"APPLICATION_APPLICATION",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"appdata",displayName:"APPLICATION_ARGUMENTS",headerCellFilter:"translate",cellClass:"ui-grid-vcenter",cellTemplate:"
{{row.entity.appdata.join(',')}}
",enableSorting:!1,enableColumnMenu:!1},{name:"interval",displayName:"APPLICATION_TIME",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"action",displayName:"APPLICATION_ACTION",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1,width:125,cellTemplate:'{{\'APPLICATION_SETTINGS\' | translate}}{{\'APPLICATION_DELETE\' | translate}}'}],onRegisterApi:function(b){b.draggableRows.on.rowDropped(a,function(b,c){a.updateRoute()})}},a.initApplication=function(b){b&&(a.selectedApp=void 0),a.forms={settings:void 0,interval:void 0},a.application={},a.interval={intType:"always",t_from:moment(new Date),t_to:moment(new Date),wd_from:"always",wd_to:"always",md_from:"always",md_to:"always",m_from:"always",m_to:"always",alwaysTime:!0},a.main={app:""}},a.$watch("interval",function(a){a&&r(a)},!0),a.updateSetAppdata=function(){a.application.variable&&a.application.value&&"Set"===a.main.app?a.application.appdata[0]=a.application.variable+"="+a.application.value:a.application.appdata[0]=null},a.updateSetAppdataSettings=function(){a.application.variable&&a.application.value&&"Set"===a.main.app?a.route.Applications[a.selectedApp].appdata[0]=a.application.variable+"="+a.application.value:a.application.appdata[0]=null},a.$watch("main.app",function(d){if(d){var e,f;switch(c.appId||(a.application={app:d,interval:a.application.interval||"*,*,*,*",appdata:[]}),d){case"Queue":e=l,f=m;break;case"Playback":e=m;break;case"AGI":e=n;break;case"Goto":e=o;break;case"Voicemail":e=q;break;default:e=null,f=null}if(e)return e.get().$promise.then(function(b){a.items=b.rows}).then(function(){return f?f.get().$promise:void 0}).then(function(b){b&&(a.items2=b.rows)})["catch"](function(a){h.show(b.instant(a.message),"danger")})}},!0),a.deselectAndRedirect=function(b){a.selectedApp=void 0,e.path(b)},a.getIntervals=function(){return p.get().$promise.then(function(b){a.Intervals=b.rows,d.syncUpdates("interval",a.Intervals)})["catch"](function(a){h.show(b.instant(a.message),"danger")})},a.getRoute=function(){return k.get({id:c.id}).$promise.then(function(b){a.route=b,a.gridOptions.data=b.Applications})["catch"](function(a){e.path("/channels/voice/routes/internal/list")})},a.getApplication=function(){console.log(a.selectedApp),void 0===a.selectedApp&&e.path("/channels/voice/routes/internal/list");var b=_.find(a.$application.applications,{value:a.route.Applications[a.selectedApp].app});if(a.main.app=b?b.value:"custom","Set"===a.main.app){var c=a.route.Applications[a.selectedApp].appdata[0].split("=");a.application.variable=c[0],a.application.value=c[1]}if(!b){var d=a.route.Applications[a.selectedApp].appdata.join(",");a.route.Applications[a.selectedApp].appdata=[d]}s()},a.openApplication=function(b){a.selectedApp=b,e.path("/channels/voice/routes/internal/view/"+c.id+"/applications/settings")},a.updateRoute=function(d){return a.selectedApp=void 0,a.route.exten=a.$application.checkUnderscore(a.route.exten),k.update({id:a.route.id},a.route).$promise.then(function(a){h.show(b.instant("MESSAGE_WELL_DONE")+"!","success"),d&&e.path("/channels/voice/routes/internal/view/"+c.id+"/"+d)})["catch"](function(a){h.show(b.instant(a.data.translatedMessage),"danger")})},a.getContexts=function(){return o.get().$promise.then(function(b){a.voiceContexts=b.rows,d.syncUpdates("voice_context",a.voiceContexts)})["catch"](function(a){h.show(b.instant(a.message),"danger")})},a.deleteApp=g.confirm["delete"](function(b){a.route.Applications.splice(b,1),a.updateRoute()}),a.addApplication=function(){a.route.Applications.push(a.application),a.updateRoute("applications")},a.goNext=function(){f.wizard().next()},a.previous=function(){f.wizard().previous()},a.formValidation=function(a){return a},a.$on("destroy",function(){d.unsyncUpdates("voice_extension")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.internal.view",{url:"/view/:id",templateUrl:"app/channels/voice/route/internal/view/view.html",controller:"VoiceRouteInternalViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.routes.internal.view.settings",{url:"/settings",templateUrl:"app/channels/voice/route/internal/view/view.settings.html"}).state("main.channels.voice.routes.internal.view.applications",{url:"/applications",templateUrl:"app/channels/voice/route/internal/view/view.applications.html"}).state("main.channels.voice.routes.internal.view.application",{url:"/application",templateUrl:"app/channels/voice/route/view.application.html"}).state("main.channels.voice.routes.internal.view.applications.settings",{url:"/settings",templateUrl:"app/channels/voice/route/view.applicationSettings.html"})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteOutboundListCreateCtrl",["$scope","$uibModalInstance","Route","application","xAlert","$translate","$location","Tag",function(a,b,c,d,e,f,g,h){a.$application=d.application,a.forms={route:void 0},a.item={type:"outbound",appdata:"Outbound Call",context:"from-sip"},a.getTags=function(){return h.get().$promise.then(function(b){b.rows.unshift({name:"--"}),a.tags=b.rows})["catch"](function(a){e.show(f.instant(a.data.translatedMessage),"danger")})},a.ok=function(){return a.item.exten=a.$application.checkUnderscore(a.item.exten),c.save(a.item).$promise.then(function(a){b.close(a),g.path("/channels/voice/routes/outbound/view/"+a.id+"/routes")})["catch"](function(a){e.show(f.instant(a.data.translatedMessage),"danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("VoiceRouteOutboundListCtrl",["$scope","$http","socket","$translate","$rootScope","xAlert","Modal","stResource","gridOptions","Route","$uibModal","$location","$log",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.initView=function(){var b={exporterCsvFilename:"OutboundRoutes.csv",columnDefs:[{name:"exten",displayName:"APPLICATION_DESTINATION_PATTERN"},{name:"description"},{name:"applications",cellClass:"ui-grid-vcenter",cellTemplate:'
{{app.app}}({{app.appdata[0]}}),...
{{\'MESSAGE_NO_AVAILABLE_APPLICATIONS\' | translate}}
',enableSorting:!1,enableFiltering:!1,enableColumnMenu:!1},{name:"action",width:170,buttons:[{"class":"blue-hoki",href:"/channels/voice/routes/outbound/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.exten, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(j,b,a,{type:"outbound"})},a.create=function(){k.open({animation:!0,templateUrl:"app/channels/voice/route/outbound/list/create.modal.html",controller:"VoiceRouteOutboundListCreateCtrl"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.outbound.list",{url:"/list",templateUrl:"app/channels/voice/route/outbound/list/list.html",controller:"VoiceRouteOutboundListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.outbound",{url:"/outbound",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VoiceRouteOutboundViewCtrl",["$scope","xAlert","$translate","$stateParams","socket","$location","WizardHandler","Modal","application","interval","Route","Trunk","VoiceContext","Interval","Tag",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o){function p(b){var c,d;if("always"===b.intType)c=null,d="*,*,*,*";else if("list"===b.intType)d=b.IntervalId?_.find(a.Intervals,{id:b.IntervalId}).name:"*,*,*,*",c=b.IntervalId||null;else if("custom"===b.intType){c=null;var e,f,g,h;e=b.t_from&&b.t_to&&!b.alwaysTime?moment(b.t_from).format("HH:mm")+"-"+moment(b.t_to).format("HH:mm"):"*",b.wd_from&&"always"!==b.wd_from?(f=b.wd_from,b.wd_to&&"always"!==b.wd_to&&(f+="-"+b.wd_to)):f="*",b.md_from&&"always"!==b.md_from?(g=b.md_from,b.md_to&&"always"!==b.md_to&&(g+="-"+b.md_to)):g="*",b.m_from&&"always"!==b.m_from?(h=b.m_from,b.m_to&&"always"!==b.m_to&&(h+="-"+b.m_to)):h="*",d=e+","+f+","+g+","+h}void 0===a.selectedApp?(a.application.interval=d,a.application.IntervalId=c):(a.route.Applications[a.selectedApp].interval=d,a.route.Applications[a.selectedApp].IntervalId=c)}function q(){if(a.interval.intType=a.route.Applications[a.selectedApp].IntervalId?"list":"*,*,*,*"===a.route.Applications[a.selectedApp].interval?"always":"custom",a.interval.IntervalId=a.route.Applications[a.selectedApp].IntervalId,!a.route.Applications[a.selectedApp].IntervalId){var b,c=a.route.Applications[a.selectedApp].interval?a.route.Applications[a.selectedApp].interval.split(","):["*","*","*","*"];c.forEach(function(c,d){switch(d){case 0:"*"!==c?(b=c.split("-"),a.interval.t_from=moment(b[0],"HH:mm"),a.interval.t_to=moment(b[1],"HH:mm"),a.interval.alwaysTime=!1):(a.interval.t_from=moment(new Date),a.interval.t_to=moment(new Date),a.interval.alwaysTime=!0);break;case 1:"*"!==c?(b=c.split("-"),a.interval.wd_from=b[0],a.interval.wd_to=b[1]?b[1]:"always"):(a.interval.wd_from="always",a.interval.wd_to="always");break;case 2:"*"!==c?(b=c.split("-"),a.interval.md_from=b[0],a.interval.md_to=b[1]?b[1]:"always"):(a.interval.md_from="always",a.interval.md_to="always");break;case 3:"*"!==c?(b=c.split("-"),a.interval.m_from=b[0],a.interval.m_to=b[1]?b[1]:"always"):(a.interval.m_from="always",a.interval.m_to="always")}})}}a.$translate=c,a.$application=i.application,a.$interval=j.interval,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.gridOptions={rowTemplate:'
',columnDefs:[{name:"app",displayName:"APPLICATION_APPLICATION",cellClass:"ui-grid-vcenter",cellTemplate:"
Default{{row.entity.app}}
",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"appdata",displayName:"APPLICATION_ARGUMENTS",headerCellFilter:"translate",cellClass:"ui-grid-vcenter",cellTemplate:"
{{row.entity.appdata.join(',')}}
",enableSorting:!1,enableColumnMenu:!1},{name:"interval",displayName:"APPLICATION_TIME",headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:"action",displayName:"APPLICATION_ACTION",enableSorting:!1,enableColumnMenu:!1,headerCellFilter:"translate",width:125,cellTemplate:'{{\'APPLICATION_SETTINGS\' | translate}}{{\'APPLICATION_DELETE\' | translate}}'}],onRegisterApi:function(b){b.draggableRows.on.rowDropped(a,function(b,c){a.updateRoute()})}},a.initApplication=function(b){b&&(a.selectedApp=void 0),a.forms={info:void 0,interval:void 0},a.application={},a.interval={intType:"always",t_from:moment(new Date),t_to:moment(new Date),wd_from:"always",wd_to:"always",md_from:"always",md_to:"always",m_from:"always",m_to:"always",alwaysTime:!0},a.main={app:""},a.applications=[{name:"Default",value:"Dial"},{name:"Custom",value:"custom"}]},a.$watch("interval",function(a){a&&p(a)},!0),a.$watch("main.app",function(e){if(e){var f,g;switch(d.appId||(a.application={app:e,interval:a.application.interval||"*,*,*,*",appdata:[]}),e){case"Dial":f=l,g=m;break;default:f=null,g=null}if(f)return f.get().$promise.then(function(b){a.items=b.rows}).then(function(){return g?g.get().$promise:void 0}).then(function(b){b&&(a.items2=b.rows)})["catch"](function(a){b.show(c.instant(a.message),"danger")})}},!0),a.deselectAndRedirect=function(b){a.selectedApp=void 0,f.path(b)},a.getIntervals=function(){return n.get().$promise.then(function(b){a.Intervals=b.rows,e.syncUpdates("interval",a.Intervals)})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.getRoute=function(){return k.get({id:d.id}).$promise.then(function(b){a.route=b,a.gridOptions.data=b.Applications})["catch"](function(a){f.path("/channels/voice/routes/outbound/list")})},a.getApplication=function(){void 0===a.selectedApp&&f.path("/channels/voice/routes/outbound/list");var b=_.find(a.applications,{value:a.route.Applications[a.selectedApp].app});if(a.main.app=b?b.value:"custom",!b){var c=a.route.Applications[a.selectedApp].appdata.join(",");a.route.Applications[a.selectedApp].appdata=[c]}q()},a.openApplication=function(b){a.selectedApp=b,f.path("/channels/voice/routes/outbound/view/"+d.id+"/routes/settings")},a.updateRoute=function(e){return a.selectedApp=void 0,a.route.exten=a.$application.checkUnderscore(a.route.exten),k.update({id:a.route.id},a.route).$promise.then(function(a){b.show(c.instant("MESSAGE_WELL_DONE")+"!","success"),e&&f.path("/channels/voice/routes/outbound/view/"+d.id+"/"+e)})["catch"](function(a){b.show(c.instant(a.data.translatedMessage),"danger")})},a.getContexts=function(){return m.get().$promise.then(function(b){a.voiceContexts=b.rows,e.syncUpdates("voice_context",a.voiceContexts)})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.getTags=function(){return o.get().$promise.then(function(b){b.rows.unshift({name:"--"}),a.tags=b.rows})["catch"](function(a){b.show(c.instant(a.data.translatedMessage),"danger")})},a.deleteApp=h.confirm["delete"](function(b){a.route.Applications.splice(b,1),a.updateRoute()}),a.addApplication=function(){a.route.Applications.push(a.application),a.updateRoute("routes")},a.goNext=function(){g.wizard().next()},a.previous=function(){g.wizard().previous()},a.formValidation=function(a){return a},a.$on("destroy",function(){e.unsyncUpdates("voice_extension")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes.outbound.view",{url:"/view/:id",templateUrl:"app/channels/voice/route/outbound/view/view.html",controller:"VoiceRouteOutboundViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.routes.outbound.view.settings",{url:"/settings",templateUrl:"app/channels/voice/route/outbound/view/view.settings.html"}).state("main.channels.voice.routes.outbound.view.routes",{url:"/routes",templateUrl:"app/channels/voice/route/outbound/view/view.routes.html"}).state("main.channels.voice.routes.outbound.view.route",{url:"/route",templateUrl:"app/channels/voice/route/outbound/view/view.route.html"}).state("main.channels.voice.routes.outbound.view.routes.settings",{url:"/settings",templateUrl:"app/channels/voice/route/outbound/view/view.routeSettings.html"})}]),angular.module("xCallyShuttleApp").factory("Route",["$resource",function(a){return a("/api/voice/extensions/:id",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.routes",{url:"/routes",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice",{url:"/voice",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("VoiceVoicemailListCtrl",["$scope","VoiceMail","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"voice_mails.csv",primaryKey:"uniqueid",columnDefs:[{name:"mailbox"},{name:"fullname"},{name:"email"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/channels/voice/voicemails/view/{{row.entity.uniqueid}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.mailbox, row.entity.uniqueid)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.voicemails.list",{url:"/list",templateUrl:"app/channels/voice/voicemail/list/list.html",controller:"VoiceVoicemailListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("VoiceVoicemailViewCtrl",["$scope","VoiceMail","VoiceMailMessage","VoiceContext","$http","xAlert","$translate","$stateParams","socket","$sce","Modal","$location","gridOptions",function(a,b,c,d,e,f,g,h,i,j,k,l,m){function n(){var b={exporterCsvFilename:"voice_mail_messages.csv",primaryKey:"id",columnDefs:[{name:"callerid"},{name:"stamp",displayName:"APPLICATION_DATE",cellClass:"ui-grid-vcenter",cellTemplate:"
{{grid.appScope.moment(row.entity.stamp).format('YYYY-MM-DD HH:mm:ss')}}
"},{name:"duration",cellClass:"ui-grid-vcenter",cellTemplate:"
{{row.entity.duration*1000 | date:'mm:ss'}}
"},{name:"audio",displayName:"",width:225,enableSorting:!1,enableFiltering:!1,buttons:[{directive:''}]},{name:"action",width:150,buttons:[{directive:''},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.id, row.entity.id)"}]}]};a.gridOptions=m.gridOptions(c,b,a,{mailbox:a.voicemail.mailbox,context:a.voicemail.context})}a.moment=moment,a.VoiceMailMessage=c,a.getVoicemail=function(){return b.get({id:h.uniqueid}).$promise.then(function(b){delete b.password,delete b.stamp,a.voicemail=b})["catch"](function(a){l.path("/voice/voicemails/list")})},a.updateVoiceVoicemail=function(){return b.update({id:h.uniqueid},a.voicemail).$promise.then(function(){f.show(g.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){f.show(g.instant(a.message),"danger")})},a.getContexts=function(){return d.get().$promise.then(function(b){a.voiceContexts=b.rows})["catch"](function(a){f.show(a.message,"danger")})},a.getMessages=function(){return a.voicemail?void n():b.get({id:h.uniqueid}).$promise.then(function(b){delete b.password,delete b.stamp,a.voicemail=b,n()})["catch"](function(a){l.path("/voice/voicemails/view/"+h.uniqueid+"/settings")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.voicemails.view",{url:"/view/:uniqueid",templateUrl:"app/channels/voice/voicemail/view/view.html",controller:"VoiceVoicemailViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.channels.voice.voicemails.view.settings",{url:"/settings",templateUrl:"app/channels/voice/voicemail/view/view.settings.html"}).state("main.channels.voice.voicemails.view.messages",{url:"/messages",templateUrl:"app/channels/voice/voicemail/view/view.messages.html"})}]),angular.module("xCallyShuttleApp").factory("VoiceMail",["$resource",function(a){return a("/api/voice/voicemails/:id/:controller",{uniqueid:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.voicemails",{url:"/voicemails",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("VoiceMailMessage",["$resource",function(a){return a("/api/voice/voicemails/messages/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("VoiceVoicemailWizardCtrl",["$scope","VoiceMail","xAlert","WizardHandler","$location","Setting",function(a,b,c,d,e,f){a.initWizard=function(){a.form={},a.item={context:"from-voicemail"}},a.next=function(){d.wizard().next()},a.previous=function(){d.wizard().previous()},a.exitValidation=function(a){return a},a.getFirstFreeMailbox=function(){f.get({controller:"mailbox"}).$promise.then(function(b){a.item.mailbox=b.value})["catch"](function(a){c.show(a.data.message,"danger")})},a.createItem=function(){return a.item.customer_id=a.item.mailbox,b.save(a.item).$promise.then(function(){e.path("/channels/voice/voicemails/list")})["catch"](function(a){c.show(data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.channels.voice.voicemails.wizard",{url:"/wizard",templateUrl:"app/channels/voice/voicemail/wizard/wizard.html",controller:"VoiceVoicemailWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("VoiceQueue",["$resource",function(a){return a("/api/voice/queues/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("Company",["$resource",function(a){return a("/api/contactmanager/companies/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.companies",{url:"/companies",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("CompanyListCreateModalCtrl",["$scope","$uibModalInstance",function(a,b){ -a.forms={dashboard:void 0},a.item={},a.ok=function(){a.item.model=JSON.stringify({title:a.item.name}),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ContactManagerCompanyListCtrl",["$scope","$http","$translate","xAlert","Modal","$uibModal","$log","Company","gridOptions","$location",function(a,b,c,d,e,f,g,h,i,j){a.initView=function(){var b={exporterCsvFilename:"Companies.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",name:"profile",href:"/contactmanager/companies/view/{{row.entity.id}}/settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(h,b,a)},a.create=function(){var a=f.open({animation:!0,templateUrl:"app/contactmanager/company/list/create.modal.html",controller:"CompanyListCreateModalCtrl"});a.result.then(function(a){b.post("/api/contactmanager/companies",a).then(function(a){j.path("/contactmanager/companies/view/"+a.id+"/settings")})["catch"](function(a){d.show(a.data.message,"danger")})},function(){g.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.companies.list",{url:"/list",templateUrl:"app/contactmanager/company/list/list.html",controller:"ContactManagerCompanyListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("ContactManagerCompanyViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location",function(a,b,c,d,e,f){a.getCompany=function(){b.get("/api/contactmanager/companies/"+e.id).success(function(b){a.company=b}).error(function(a){f.path("/contactmanager/companies/list")})},a.updateCompany=function(){var f=angular.copy(a.company);b.put("/api/contactmanager/companies/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(b){c.show(d.instant(b.message),"danger"),a.company=f})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.companies.view",{url:"/view/:id",templateUrl:"app/contactmanager/company/view/view.html",controller:"ContactManagerCompanyViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.contactmanager.companies.view.settings",{url:"/settings",templateUrl:"app/contactmanager/company/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("Contact",["$resource",function(a){return a("/api/contactmanager/contacts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.contacts",{url:"/contacts",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ContactManagerListImportModalCtrl",["$scope","$uibModalInstance","indexes","csv","xAlert","socket","Service","Contact","$translate",function(a,b,c,d,e,f,g,h,i){function j(b){if(b>=a.csvLength||a.stopped)return void(a.importing=!1);var c={Phones:[],Emails:[],customFields:{}};return _.forOwn(a.item,function(e,f){switch(f){case"tags":c.tags=[],a.item.tags.forEach(function(a){""!==d[b][a]&&c.tags.push(d[b][a])});break;default:c[f]=d[b][e]}}),c.tags=c.tags?c.tags.join(","):void 0,c.ServiceId=a.item.ServiceId,c.CompanyId=a.item.CompanyId||null,h.save(c).$promise.then(function(c){a["import"].success+=k,a["import"].succeeded+=1,j(b+1)})["catch"](function(c){a["import"].fail+=k,a["import"].failed+=1,j(b+1)})}a.indexes=c,a.importing=!1,a.submitted=!1,a.stopped=!1,a["import"]={success:0,fail:0,succeeded:0,failed:0},a.csvLength=d.length;var k=100/a.csvLength;a.forms={dashboard:void 0},a.item={},a.start=function(){a.importing=!0,a.submitted=!0,j(0)},a.getServices=function(){return g.get().$promise.then(function(b){a.services=b.rows,a.item.ServiceId=1,a.getCustomFields()})["catch"](function(a){e.show(i.instant(a.message)+"!","danger")})},a.getCustomFields=function(){return g.get({serviceId:a.item.ServiceId,controller:"customfields"}).$promise.then(function(b){b.rows.forEach(function(a){a.values=JSON.parse(a.values)}),a.customFields=b.rows,f.socket.on("custom_field:remove",function(b){_.remove(a.customFields,function(a){return b.id==a.id})}),f.socket.on("custom_field:save",function(b){if(b.ServiceId===a.item.ServiceId){var c=_.find(a.customFields,{id:b.id});c||("string"==typeof b.values&&(b.values=JSON.parse(b.values)),a.customFields.push(b))}})})["catch"](function(a){console.error(a),e.show(a.message,"danger")})},a.close=function(){b.close()},a.stop=function(){a.stopped=!0}}]),angular.module("xCallyShuttleApp").controller("ContactManagerContactListCtrl",["$scope","$translate","Modal","FileUploader","Papa","$uibModal","$log","Contact","gridOptions","Service","uiGridConstants","xAlert","socket",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.initView=function(){return j.get().$promise.then(function(b){a.services=[],b.rows.forEach(function(b,c){a.services.push({value:b.id,label:b.name})})}).then(function(){var b={exporterCsvFilename:"Contacts.csv",columnDefs:[{name:"firstName"},{name:"lastName"},{name:"phone"},{name:"mobile"},{name:"email"},{name:"ServiceId",displayName:"APPLICATION_SERVICE",field:"Service.name",filter:{type:k.filter.SELECT,selectOptions:a.services}},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",name:"profile",onClick:"grid.appScope.openContactTab(row.entity)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.fullname, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(h,b,a)})["catch"](function(a){l.show(b.instant(a.message)+"!","danger")})},d.FileSelect.prototype.isEmptyAfterSelection=function(){return!0};var n=a.uploader=new d({queueLimit:1,clearInputAfterAddedToQueue:!0});n.onAfterAddingFile=function(b){console.log("fileadded"),e.parse(b._file,{header:!0,complete:function(b){a.uploader.clearQueue(),a["import"](b.data)},error:function(a){console.log(a)}})},a["import"]=function(b){var c=f.open({animation:!0,size:"lg",backdrop:"static",keyboard:!1,templateUrl:"app/contactmanager/contact/list/import.modal.html",controller:"ContactManagerListImportModalCtrl",resolve:{indexes:function(){return _.keys(b[0])},csv:function(){return b}}});c.result.then(function(b){a.gridOptions.getPage()},function(){g.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.contacts.list",{url:"/list",templateUrl:"app/contactmanager/contact/list/list.html",controller:"ContactManagerContactListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager",{url:"/contactmanager",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("ContactManagerServiceListCreateModalCtrl",["$scope","$uibModalInstance",function(a,b){a.forms={dashboard:void 0},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ContactManagerServiceListCtrl",["$scope","$http","$translate","Modal","xAlert","$uibModal","$log","Service","gridOptions",function(a,b,c,d,e,f,g,h,i){a.initView=function(){var b={exporterCsvFilename:"Services.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",name:"settings",href:"/contactmanager/services/view/{{row.entity.id}}/settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=i.gridOptions(h,b,a)},a.create=function(){var d=f.open({animation:!0,templateUrl:"app/contactmanager/service/list/create.modal.html",controller:"ContactManagerServiceListCreateModalCtrl"});d.result.then(function(d){b.post("/api/contactmanager/services/",d).then(function(b){a.gridOptions.getPage(),e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})},function(){g.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.services.list",{url:"/list",templateUrl:"app/contactmanager/service/list/list.html",controller:"ContactManagerServiceListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Service",["$resource",function(a){return a("/api/contactmanager/services/:serviceId/:controller/:id",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.services",{url:"/services",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ContactManagerServiceCustomFieldViewCreateModalCtrl",["$scope","$uibModalInstance","$translate",function(a,b,c){a.$translate=c,a.forms={dashboard:void 0},a.item={},a.choices=[{value:""}],a.addField=function(){a.choices.push({})},a.removeField=function(b){a.choices.splice(b,1)},a.types=[{name:"APPLICATION_TEXT",value:"text"},{name:"APPLICATION_SELECT",value:"select"}],a.ok=function(){"select"===a.item.type&&(a.item.values=angular.toJson(a.choices)),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("ContactManagerServiceViewCtrl",["$scope","xAlert","$translate","$stateParams","socket","$location","$uibModal","$log","Modal","Service","Team","gridOptions",function(a,b,c,d,e,f,g,h,i,j,k,l){var m=function(){return{select:function(b){return j.save({serviceId:a.service.id,controller:"agents"},{agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})},deselect:function(b){return j["delete"]({serviceId:a.service.id,controller:"agents",agents:b}).$promise.then(function(){a.getTeams()})["catch"](function(a){console.log(a)})}}};a.getService=function(){return j.get({serviceId:d.id}).$promise.then(function(b){a.service=b})["catch"](function(a){f.path("/contactmanager/services/list")})},a.updateService=function(){return j.update({serviceId:d.id},a.service).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.getTeams=function(){return k.get().$promise.then(function(b){return a.teams=b.rows,j.query({serviceId:d.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindQueue(a.teams,_.map(b,function(a){return{id:a.id}}),m)})["catch"](function(a){console.error(a)})},a.initCustomFields=function(){var b={exporterCsvFilename:"customfields.csv",primaryKey:"id",columnDefs:[{name:"alias",displayName:"APPLICATION_NAME"},{name:"type"},{name:"description"},{name:"action",width:200,buttons:[{"class":"blue-hoki",href:"/contactmanager/services/view/{{grid.appScope.$stateParams.id}}/customfields/settings/{{row.entity.id}}",name:"settings"},{"class":"red-sunglo",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)",name:"delete"}]}]};a.gridOptions=l.gridOptions(j,b,a,{serviceId:d.id,controller:"customfields"})},a.create=function(){var e=g.open({animation:!0,templateUrl:"app/contactmanager/service/view/create.modal.html",controller:"ContactManagerServiceCustomFieldViewCreateModalCtrl"});e.result.then(function(e){return j.save({serviceId:d.id,controller:"customfields"},e).$promise.then(function(d){a.gridOptions.getPage(),b.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){b.show(a.message||a.data.message,"danger")})},function(){h.info("Modal dismissed at: "+new Date)})},a.getCustomField=function(){return j.get({serviceId:d.id,controller:"customfields",id:d.cfId}).$promise.then(function(b){console.log(b),a.customField=b,"select"===a.customField.type&&(a.choices=JSON.parse(a.customField.values))})["catch"](function(a){console.error(a),f.path("/contactmanager/customfields/list")})},a.updateCustomField=function(){var e=angular.copy(a.customField);return"select"===e.type&&(e.values=angular.toJson(a.choices)),j.update({serviceId:d.id,controller:"customfields",id:d.cfId},e).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(c.instant(a.message),"danger")})},a.addField=function(){a.choices.push({})},a.removeField=function(b){a.choices.splice(b,1)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.contactmanager.services.view",{url:"/view/:id",templateUrl:"app/contactmanager/service/view/view.html",controller:"ContactManagerServiceViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.contactmanager.services.view.settings",{url:"/settings",templateUrl:"app/contactmanager/service/view/view.settings.html"}).state("main.contactmanager.services.view.agents",{url:"/agents",templateUrl:"app/contactmanager/service/view/view.agents.html",cache:!1,serie:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]})}]}}).state("main.contactmanager.services.view.customfields",{url:"/customfields",templateUrl:"app/contactmanager/service/view/view.customFields.html"}).state("main.contactmanager.services.view.customfields.settings",{url:"/settings/:cfId",templateUrl:"app/contactmanager/service/view/view.customFieldSettings.html",controller:"ContactManagerServiceViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("DashboardCtrl",["$scope","$translate",function(a,b){a.voice=[{name:b.instant("APPLICATION_QUEUE"),link:"main.dashboard.voice"}],a.mail=[{name:b.instant("APPLICATION_QUEUE"),link:"main.dashboard.mail"}]}]),angular.module("xCallyShuttleApp").factory("Dashboard",["$resource",function(a){return a("/api/dashboards/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.dashboard",{"abstract":!0,url:"/dashboard",templateUrl:"app/dashboard/dashboard.html",controller:"DashboardCtrl"}).state("main.dashboard.voice",{url:"/voice",controller:"DashboardVoiceCtrl",templateUrl:"app/dashboard/voice/voice.html"}).state("main.dashboard.mail",{url:"/mail",controller:"DashboardMailCtrl",templateUrl:"app/dashboard/mail/mail.html"})}]),angular.module("xCallyShuttleApp").controller("DashboardMailCtrl",["$scope",function(a){a.message="Hello"}]),angular.module("xCallyShuttleApp").controller("DashboardVoiceCtrl",["$scope","Auth","ReportQueue","ReportCall","socket",function(a,b,c,d,e){a.Auth=b,a.initWaiting=function(){return c.get({id:"waiting"}).$promise.then(function(b){a.waiting=b.value,e.socket.on("dashboard:waiting",function(b){a.waiting=b.value})})["catch"](function(a){console.error(a)})},a.initActive=function(){return c.get({id:"active"}).$promise.then(function(b){a.active=b.value,e.socket.on("dashboard:active",function(b){a.active=b.value})})["catch"](function(a){console.error(a)})},a.initAnswered=function(){return c.get({id:"answered"}).$promise.then(function(b){a.answered=b.value,e.socket.on("dashboard:answered",function(b){a.answered=b.value})})["catch"](function(a){console.error(a)})},a.initAbandoned=function(){return c.get({id:"abandoned"}).$promise.then(function(b){a.abandoned=b.value,e.socket.on("dashboard:abandoned",function(b){a.abandoned=b.value})})["catch"](function(a){console.error(a)})},a.initAvgAnswerTime=function(){return c.get({id:"avganswertime"}).$promise.then(function(b){a.avganswertime=b.value,e.socket.on("dashboard:avganswertime",function(b){a.avganswertime=b.value})})["catch"](function(a){console.error(a)})},a.initAvgTalkTime=function(){return c.get({id:"avgtalktime"}).$promise.then(function(b){a.avgtalktime=b.value,e.socket.on("dashboard:avgtalktime",function(b){a.avgtalktime=b.value})})["catch"](function(a){console.error(a)})},a.initAnswerRate=function(){return c.get({id:"answerrate"}).$promise.then(function(b){a.answerrate=b.value,e.socket.on("dashboard:answerrate",function(b){a.answerrate=b.value})})["catch"](function(a){console.error(a)})},a.initTotalOffered=function(){return c.get({id:"totaloffered"}).$promise.then(function(b){a.totaloffered=b.value,e.socket.on("dashboard:totaloffered",function(b){a.totaloffered=b.value})})["catch"](function(a){console.error(a)})},a.initUnmanaged=function(){return c.get({id:"unmanaged"}).$promise.then(function(b){a.unmanaged=b.value,e.socket.on("dashboard:unmanaged",function(b){a.unmanaged=b.value})})["catch"](function(a){console.error(a)})},a.initAbandonRate=function(){return c.get({id:"abandonrate"}).$promise.then(function(b){a.abandonrate=b.value,e.socket.on("dashboard:abandonrate",function(b){a.abandonrate=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutbound=function(){return d.get({id:"manualoutbound"}).$promise.then(function(b){a.manualoutbound=b.value,e.socket.on("dashboard:manualoutbound",function(b){a.manualoutbound=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutboundGlobalDuration=function(){return d.get({id:"manualoutboundglobalduration"}).$promise.then(function(b){a.manualoutboundglobalduration=b.value,e.socket.on("dashboard:manualoutboundglobalduration",function(b){a.manualoutboundglobalduration=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutboundAvgDuration=function(){return d.get({id:"manualoutboundavgduration"}).$promise.then(function(b){a.manualoutboundavgduration=b.value,e.socket.on("dashboard:manualoutboundavgduration",function(b){a.manualoutboundavgduration=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutboundAnswered=function(){return d.get({id:"manualoutboundanswered"}).$promise.then(function(b){a.manualoutboundanswered=b.value,e.socket.on("dashboard:manualoutboundanswered",function(b){a.manualoutboundanswered=b.value})})["catch"](function(a){console.error(a)})},a.initManualOutboundAnswerRate=function(){return d.get({id:"manualoutboundanswerrate"}).$promise.then(function(b){a.manualoutboundanswerrate=b.value,e.socket.on("dashboard:manualoutboundanswerrate",function(b){a.manualoutboundanswerrate=b.value})})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.desk",{url:"/desk",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("DeskAccount",["$resource",function(a){return a("/api/desk/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("DeskListCtrl",["$scope","$http","$rootScope","xAlert","$translate","socket","Modal","stResource",function(a,b,c,d,e,f,g,h){a.conf={accountsByPage:{name:"10",value:10}},a.accountsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.accounts={checked:[]},a.check=function(b,c){c?a.accounts.checked=angular.copy(_.map(a.displayedDeskAccounts,"id")):a.accounts.checked=[]},a.getAccounts=function(b){return _.map(a.displayedDeskAccounts,function(a){var c={};return b.forEach(function(b){c[b]=a[b]}),c})},a.initList=function(b){f.unsyncUpdates("desk_account"),b.url="/api/desk/accounts",h.getPage(b).then(function(d){a.displayedDeskAccounts=d.rows,b.pagination.numberOfPages=d.total_pages,c.updateTableConfig(a.accountsByPage,a.displayedDeskAccounts.length),c.updateTableConfig(a.conf.accountsByPage,a.displayedDeskAccounts.length)}),f.socket.on("desk_account:save",function(){a.initList(b)}),f.socket.on("desk_account:remove",function(c){a.accounts.checked=_.without(a.accounts.checked,c.id),a.initList(b)})},a.deleteItem=g.confirm["delete"](function(a){b["delete"]("/api/desk/accounts/"+a).success(function(){d.show(e.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.deleteItems=g.confirm["delete"](function(){b["delete"]("/api/desk/accounts",{params:{id:a.accounts.checked}}).success(function(){d.show(e.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.checkAccount=function(a){b.get("/api/desk/accounts/"+a+"/check").then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.desk.list",{url:"/list",templateUrl:"app/desk/list/list.html",controller:"DeskListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("DeskViewCtrl",["$scope","$http","$stateParams","$translate","$location","WizardHandler","socket","xAlert","Modal","desk_com",function(a,b,c,d,e,f,g,h,i,j){a.$stateParams=c,a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:500,scrollInertia:0},a.initConfiguration=function(){a.formsConfiguration={},a.configuration={}},a.goNext=function(){f.wizard().next()},a.formValidation=function(a){return a},a.$on("$destroy",function(){g.unsyncUpdates("desk_configuration"),g.unsyncUpdates("desk_field")}),a.initView=function(){b.get("/api/desk/accounts/"+c.id).success(function(b){a.account=b}).error(function(a){h.show(a.message,"danger")})},a.updateItem=function(){b.put("/api/desk/accounts/"+c.id,a.account).success(function(){h.show(d.instant("MESSAGE_WELL_DONE")+".","success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getConfigurations=function(){b.get("/api/desk/configurations",{params:{AccountId:c.id}}).success(function(b){a.configurations=b,g.socket.on("desk_configuration:remove",function(b){_.remove(a.configurations,{id:b.id})})}).error(function(a){h.show(a.message,"danger")})},a.deleteConfiguration=i.confirm["delete"](function(a){b["delete"]("api/desk/configurations/"+a).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.createConfiguration=function(){a.configuration.AccountId=c.id,b.post("api/desk/configurations",a.configuration).success(function(a){e.path("desk/view/"+c.id+"/configurations/settings/"+a.id)}).error(function(){h.show("Something went wrong!","danger")})},a.fieldType=["string","variable"],a.descFieldType=["string","key_value"],a.getFields=function(){b.get("/api/desk/accounts/"+c.id+"/fields").success(function(b){a.accountFields=j.fields.concat(b)}).error(function(a){h.show(a.message,"danger")})},a.getConfiguration=function(){b.get("/api/desk/configurations/"+c.configurationId).success(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,g.socket.on("desk_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})}).error(function(a){h.show(a.message,"danger")})},a.getVariables=function(){b.get("/api/variables").success(function(b){a.variables=b.rows}).error(function(a){h.show(a.message,"danger")})},a.removeItem=function(a){b["delete"]("api/desk/fields/"+a.id).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.addItemSubject=function(){var d={type:"string",content:""};b.post("/api/desk/configurations/"+c.configurationId+"/subject",d).success(function(b){a.subjectConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.addItemDescription=function(){var d={type:"string",content:""};b.post("/api/desk/configurations/"+c.configurationId+"/description",d).success(function(b){a.descriptionConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.addItemField=function(){var d={content:""};b.post("/api/desk/configurations/"+c.configurationId+"/field",d).success(function(b){a.fieldConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.updateField=function(a){b.put("/api/desk/fields/"+a.id,a).success(function(){}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.changeType=function(b){"variable"===b.type?b.content="":"string"===b.type&&(b.VariableId=null),a.updateField(b)},a.changeDescType=function(b){"key_value"===b.type?(b.content="","string"===b.keyType?b.VariableId=null:"variable"===b.keyType&&(b.keyContent="")):"string"===b.type&&(b.VariableId=null,b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){if(b.content="",b.idField){var c=_.find(a.accountFields,"id",b.idField);c&&(b.customField=_.result(c,"custom",!0))}a.updateField(b)},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"id",b);return c?c.data.choices?c.data.choices:null:void 0}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.desk.view",{url:"/view/:id",templateUrl:"app/desk/view/view.html",controller:"DeskViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.desk.view.account",{url:"/account",templateUrl:"app/desk/view/view.account.html"}).state("main.desk.view.configurations",{url:"/configurations",templateUrl:"app/desk/view/view.configurations.html"}).state("main.desk.view.configurations.settings",{url:"/settings/:configurationId",templateUrl:"app/desk/view/view.configurationSettings.html",controller:"DeskViewCtrl"}).state("main.desk.view.configuration",{url:"/configuration",templateUrl:"app/desk/view/view.configuration.html"})}]),angular.module("xCallyShuttleApp").controller("DeskWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={}},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){console.log(a.item),b.post("api/desk/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/desk/list")}).error(function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.desk.wizard",{url:"/wizard",templateUrl:"app/desk/wizard/wizard.html",controller:"DeskWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.freshdesk",{url:"/freshdesk",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("FreshdeskAccount",["$resource",function(a){return a("/api/freshdesk/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("FreshdeskListCtrl",["$scope","$http","$rootScope","xAlert","$translate","socket","Modal","stResource",function(a,b,c,d,e,f,g,h){a.conf={accountsByPage:{name:"10",value:10}},a.accountsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.accounts={checked:[]},a.check=function(b,c){c?a.accounts.checked=angular.copy(_.map(a.displayedFreshdeskAccounts,"id")):a.accounts.checked=[]},a.getAccounts=function(b){return _.map(a.displayedFreshdeskAccounts,function(a){var c={};return b.forEach(function(b){c[b]=a[b]}),c})},a.initList=function(b){f.unsyncUpdates("freshdesk_account"),b.url="/api/freshdesk/accounts",h.getPage(b).then(function(d){a.displayedFreshdeskAccounts=d.rows,b.pagination.numberOfPages=d.total_pages,c.updateTableConfig(a.accountsByPage,a.displayedFreshdeskAccounts.length),c.updateTableConfig(a.conf.accountsByPage,a.displayedFreshdeskAccounts.length)}),f.socket.on("freshdesk_account:save",function(){a.initList(b)}),f.socket.on("freshdesk_account:remove",function(c){a.accounts.checked=_.without(a.accounts.checked,c.id),a.initList(b)})},a.deleteItem=g.confirm["delete"](function(a){b["delete"]("/api/freshdesk/accounts/"+a).success(function(){d.show(e.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.deleteItems=g.confirm["delete"](function(){b["delete"]("/api/freshdesk/accounts",{params:{id:a.accounts.checked}}).success(function(){d.show(e.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.checkAccount=function(a){b.get("/api/freshdesk/accounts/"+a+"/check").then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.freshdesk.list",{url:"/list",templateUrl:"app/freshdesk/list/list.html",controller:"FreshdeskListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("FreshdeskViewCtrl",["$scope","$http","$stateParams","$translate","$location","$filter","WizardHandler","socket","xAlert","Modal",function(a,b,c,d,e,f,g,h,i,j){a.$stateParams=c,a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:500,scrollInertia:0},a.initConfiguration=function(){a.formsConfiguration={},a.configuration={}},a.goNext=function(){g.wizard().next()},a.formValidation=function(a){return a},a.$on("$destroy",function(){h.unsyncUpdates("freshdesk_configuration"),h.unsyncUpdates("freshdesk_field")}),a.initView=function(){b.get("/api/freshdesk/accounts/"+c.id).success(function(b){a.account=b}).error(function(a){i.show(a.message,"danger")})},a.updateItem=function(){b.put("/api/freshdesk/accounts/"+c.id,a.account).success(function(){i.show(d.instant("MESSAGE_WELL_DONE")+".","success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getConfigurations=function(){b.get("/api/freshdesk/configurations",{params:{AccountId:c.id}}).success(function(b){a.configurations=b,h.socket.on("freshdesk_configuration:remove",function(b){_.remove(a.configurations,{id:b.id})})}).error(function(a){i.show(a.message,"danger")})},a.deleteConfiguration=j.confirm["delete"](function(a){b["delete"]("api/freshdesk/configurations/"+a).success(function(){i.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.createConfiguration=function(){a.configuration.AccountId=c.id,b.post("api/freshdesk/configurations",a.configuration).success(function(a){e.path("freshdesk/view/"+c.id+"/configurations/settings/"+a.id)}).error(function(){i.show("Something went wrong!","danger")})},a.fieldType=["string","variable"],a.descFieldType=["string","key_value"],a.getFields=function(){b.get("/api/freshdesk/accounts/"+c.id+"/fields").success(function(b){a.accountFields=[],b=f("freshdesk")(b),_.forEach(b,function(b){ -a.accountFields.push(b.ticket_field)})}).error(function(a){i.show(a.message,"danger")})},a.getConfiguration=function(){b.get("/api/freshdesk/configurations/"+c.configurationId).success(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,h.socket.on("freshdesk_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})}).error(function(a){i.show(a.message,"danger")})},a.getVariables=function(){b.get("/api/variables").success(function(b){a.variables=b.rows}).error(function(a){i.show(a.message,"danger")})},a.removeItem=function(a){b["delete"]("api/freshdesk/fields/"+a.id).success(function(){i.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.addItemSubject=function(){var d={type:"string",content:""};b.post("/api/freshdesk/configurations/"+c.configurationId+"/subject",d).success(function(b){a.subjectConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.addItemDescription=function(){var d={type:"string",content:""};b.post("/api/freshdesk/configurations/"+c.configurationId+"/description",d).success(function(b){a.descriptionConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.addItemField=function(){var d={content:""};b.post("/api/freshdesk/configurations/"+c.configurationId+"/field",d).success(function(b){a.fieldConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.updateField=function(a){b.put("/api/freshdesk/fields/"+a.id,a).success(function(){}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.changeType=function(b){"variable"===b.type?b.content="":"string"===b.type&&(b.VariableId=null),a.updateField(b)},a.changeDescType=function(b){"key_value"===b.type?(b.content="","string"===b.keyType?b.VariableId=null:"variable"===b.keyType&&(b.keyContent="")):"string"===b.type&&(b.VariableId=null,b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){if(b.content="",b.idField){var c=_.find(a.accountFields,"name",b.idField);c&&(b.customField=!_.result(c,"default",!0))}a.updateField(b)},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"name",b);return c?c.choices.length>0?c.choices:null:void 0}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.freshdesk.view",{url:"/view/:id",templateUrl:"app/freshdesk/view/view.html",controller:"FreshdeskViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.freshdesk.view.account",{url:"/account",templateUrl:"app/freshdesk/view/view.account.html"}).state("main.freshdesk.view.configurations",{url:"/configurations",templateUrl:"app/freshdesk/view/view.configurations.html"}).state("main.freshdesk.view.configurations.settings",{url:"/settings/:configurationId",templateUrl:"app/freshdesk/view/view.configurationSettings.html",controller:"FreshdeskViewCtrl"}).state("main.freshdesk.view.configuration",{url:"/configuration",templateUrl:"app/freshdesk/view/view.configuration.html"})}]),angular.module("xCallyShuttleApp").controller("FreshdeskWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={}},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){console.log(a.item),b.post("api/freshdesk/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/freshdesk/list")}).error(function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.freshdesk.wizard",{url:"/wizard",templateUrl:"app/freshdesk/wizard/wizard.html",controller:"FreshdeskWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.integrations",{url:"/integrations",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("Integration",["$resource",function(a){return a("/api/integrations/:id/:controller",{id:"@id"})}]),angular.module("xCallyShuttleApp").controller("IntegrationListCtrl",["$scope","Modal","socket","FileUploader","Integration","xAlert",function(a,b,c,d,e,f){a.integrationsByPage=10;var g=a.uploader=new d({url:"api/integrations",autoUpload:!0,removeAfterUpload:!0});g.filters.push({name:"zipFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|zip|".indexOf(b)}}),g.onSuccessItem=function(a,b,c,d){console.info("onSuccessItem",a,b,c,d),f.show(b.name,"success")},g.onErrorItem=function(a,b,c,d){console.info("onErrorItem",a,b,c,d),b.errors.forEach(function(a){f.show(a.message,"danger")})},a.deleteItem=b.confirm["delete"](function(a){e["delete"]({id:a},function(){f.show("Integration Removed","success")},function(a){f.show(a.data.errors,"danger")})}),a.initList=function(){a.integrations=e.query({},function(a){c.syncUpdates("integration",a)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.integrations.list",{url:"/list",templateUrl:"app/integration/list/list.html",controller:"IntegrationListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js"]})}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty",{url:"/jscripty",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("JscriptyProject",["$resource",function(a){return a("/api/jscripty/projects/:id/:controller/:action/:action2",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("JscriptyProjectListCtrl",["$scope","$uibModal","JscriptyProject","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"jscriptyProjects.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:300,buttons:[{"class":"blue-hoki",href:"/jscripty/projects/view/{{row.entity.id}}",name:"settings"},{"class":"green",name:"start",onClick:"grid.appScope.openJscriptyTab(row.entity)"},{"class":"purple",href:"/jscripty/projects/report/{{row.entity.id}}/sessions",name:"report"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/jscripty/project/list/list.create.modal.html",controller:"JscriptyProjectListCreateCtrl"});c.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("JscriptyProjectListCreateCtrl",["$scope","$translate","$uibModalInstance","JscriptyProject","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){console.log(a),e.show(b.instant(a.data.translatedMessage),"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty.projects.list",{url:"/list",templateUrl:"app/jscripty/project/list/list.html",controller:"JscriptyProjectListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty.projects",{url:"/projects",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("JscriptyProjectReportCtrl",["$scope","$http","$state","$stateParams","socket","Auth","Modal","xAlert","$translate","$rootScope","gridOptions","JscriptyProject","$location",function(a,b,c,d,e,f,g,h,i,j,k,l,m){a.projectStats={started:0,incomplete:0,completed:0},a.projectId=d.id,a.initView=function(){return l.get({id:d.id,controller:"sessions"}).$promise.then(function(b){a.projectId=d.id,console.log(a.projectId);var c=_.groupBy(b.rows,"status");a.projectStats.started=c.started?c.started.length:0,a.projectStats.completed=c.completed?c.completed.length:0,a.projectStats.incomplete=c.incomplete?c.incomplete.length:0})["catch"](function(a){h.show(a.message,"danger")})},a.getProjectSessions=function(){var b={exporterCsvFilename:"jscriptyProjects.csv",columnDefs:[{name:"projectId",displayName:"APPLICATION_PROJECTID"},{name:"session_id",displayName:"APPLICATION_SESSIONID"},{name:"createdAt",displayName:"APPLICATION_STARTEDAT"},{name:"completedAt",displayName:"APPLICATION_COMPLETEDAT"},{name:"status",displayName:"APPLICATION_STATUS"},{name:"last_question_id",displayName:"APPLICATION_LASTQUESTIONID"},{name:"action",width:100,buttons:[{"class":"blue-hoki",href:"/jscripty/projects/report/{{row.entity.projectId}}/session/{{row.entity.session_id}}",name:"Detail"}]}]};a.gridOptions=k.gridOptions(l,b,a,{id:d.id,controller:"sessions"})},a.getSessionDetails=function(){console.log(d.sessionId),b.get("/api/jscripty/projects/"+d.id+"/sessions/"+d.sessionId).success(function(b){a.sessionQuestions=b[0],console.log("session",a.sessionQuestions)})["catch"](function(a){h.show(a.message,"danger")})},a.getQuestionSummary=function(){var b={exporterCsvFilename:"jscriptyProjects.csv",columnDefs:[{name:"question_id",width:150,displayName:"APPLICATION_QUESTIONID"},{name:"question_type",width:150,displayName:"APPLICATION_QUESTIONTYPE"},{name:"question_label",width:200,displayName:"APPLICATION_QUESTIONLABEL"},{name:"question_text",displayName:"APPLICATION_QUESTION"},{name:"count",width:100,displayName:"APPLICATION_COUNT"}]};a.gridOptions=k.gridOptions(l,b,a,{id:d.id,controller:"questions",action:"summary"})},a.getQuestionDetail=function(){b.get("/api/jscripty/projects/"+d.id+"/questions/detail").success(function(b){var c=_.groupBy(b,"question_id");_.forEach(c,function(a,b){c[b]=_.groupBy(a,"question_label"),_.forEach(c[b],function(a,d){c[b][d]=_.groupBy(a,"question_text")})}),a.questionDetail=c,console.log("detail",a.questionDetail)})["catch"](function(a){h.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty.projects.report",{url:"/report/:id",templateUrl:"app/jscripty/project/report/report.html",controller:"JscriptyProjectReportCtrl"}).state("main.jscripty.projects.report.sessions",{url:"/sessions",templateUrl:"app/jscripty/project/report/report.sessions.html"}).state("main.jscripty.projects.report.summary",{url:"/summary",templateUrl:"app/jscripty/project/report/report.summary.html"}).state("main.jscripty.projects.report.detail",{url:"/detail",templateUrl:"app/jscripty/project/report/report.detail.html"}).state("main.jscripty.projects.report.sessionDetail",{url:"/session/:sessionId",controller:"JscriptyProjectReportCtrl",templateUrl:"app/jscripty/project/report/report.session.detail.html"})}]),angular.module("xCallyShuttleApp").controller("JscriptyProjectViewCtrl",["$scope","$http","$state","$stateParams","socket","Auth","Modal","xAlert","$translate","$rootScope",function(a,b,c,d,e,f,g,h,i,j){a.jscriptyProject={},a.getProject=function(){b.get("/api/jscripty/projects/"+d.id).success(function(b){a.jscriptyProject=b,angular.element(document).ready(function(){window.onerror=function(a,b,c){try{if(null!=a&&-1!=a.indexOf("Script error."));else{var d=new Image;d.src="assets/plugins/mxgraph/images/1x1.png?msg="+encodeURIComponent(a)+"&url="+encodeURIComponent(b)+"&lnum="+encodeURIComponent(c)}}catch(e){}},b.token=f.getToken();var a=new EditorUi(new Editor);a.openString(b.draft,b.name,b),a.editor.graphChangeListener=function(a,b){var c=b.properties.rtChange||!1;c||(this.modified=!0)}}),e.syncUpdates("jscripty_project",[b],function(a,c,d){c.id===b.id})})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.jscripty.projects.view",{url:"/view/:id",templateUrl:"app/jscripty/project/view/view.html",controller:"JscriptyProjectViewCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",serie:!0,cache:!1,files:["assets/plugins/mxgraph/css/common.css","assets/plugins/mxgraph/css/explorer.css","assets/plugins/mxgraph/styles/grapheditor.css","assets/plugins/mxgraph/styles/custom.css","assets/plugins/jscripty/js/custom.js","assets/plugins/mxgraph/js/mxClient.js","assets/plugins/jscripty/js/Editor.js","assets/plugins/jscripty/js/Graph.js","assets/plugins/jscripty/js/EditorUi.js","assets/plugins/jscripty/js/Actions.js","assets/plugins/jscripty/js/Menus.js","assets/plugins/jscripty/js/Sidebar.js","assets/plugins/jscripty/js/Toolbar.js","assets/plugins/jscripty/js/Dialogs.js"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("LoginCtrl",["$scope","Auth","$location","$window","$rootScope",function(a,b,c,d,e){a.year=moment().year(),a.userLogin={},a.userSignUp={},a.loginSubmitted=!1,a.signupSubmitted=!1,a.errorLogin=!1,a.errorSignup=!1,a.errorLog="",a.flagLogin1=!1,a.toogleLogin=function(){a.flagLogin1=!a.flagLogin1},e.bodyLayout="login",a.$on("$viewContentLoaded",function(){Metronic.init(),Layout.init()}),a.login=function(d){a.loginSubmitted=!0,d.$valid?b.login({name:a.userLogin.name,password:a.userLogin.password,remember:a.userLogin.remember}).then(function(){c.path("/dashboard/voice")})["catch"](function(b){a.errorLog=b.message,a.errorLogin=!0}):a.errorLogin=!0},a.signup=function(d){a.signupSubmitted=!0,d.$valid?b.createUser({email:a.userSignUp.email,fullname:a.userSignUp.fullname,name:a.userSignUp.name,password:a.userSignUp.password,role:a.userSignUp.role,online:!0}).then(function(){c.path("/")})["catch"](function(b){a.errorLog=b.message,a.errorSignup=!0}):a.errorSignup=!0},a.loginOauth=function(a){d.location.href="/auth/"+a}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("login",{url:"/login",templateUrl:"app/login/login.html",controller:"LoginCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/login.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Action",["$resource",function(a){return a("/api/actions/:name/:controller",{name:"@name"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").directive("actionBuilderTemplate",["$compile","xAlert","$http","$timeout","Template","$translate",function(a,b,c,d,e,f){return{restrict:"E",scope:{element:"=",form:"="},templateUrl:"app/main/template/actionBuilder/template.actionBuilderTemplate.html",compile:function(c,g){var h,i;return h=c.contents().remove(),function(c,g,j){function k(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")}c.randomName=k(),d(function(){return e.get().$promise.then(function(a){c.templates=a.rows})["catch"](function(a){b.show(f.instant(a.message),"danger")})}),i||(i=a(h)),g.append(i(c,function(a){return a}))}}}}]).directive("actionBuilderIntegration",["$compile","xAlert","$http","$timeout","Integration","$translate","ZendeskAccount","DeskAccount","SalesforceAccount","FreshdeskAccount","SugarcrmAccount",function(a,b,c,d,e,f,g,h,i,j,k){return{restrict:"E",scope:{element:"=",form:"="},templateUrl:"app/main/template/actionBuilder/template.actionBuilderIntegration.html",compile:function(c,l){var m,n;return m=c.contents().remove(),function(c,l,o){function p(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")}c.randomName=p(),d(function(){return e.get({active:1}).$promise.then(function(a){c.integrations=a.rows,c.element.data1&&q()})["catch"](function(a){b.show(f.instant(a.message),"danger")})});var q=function(){var a;switch(c.element.data1){case"zendesk":a=g;break;case"desk":a=h;break;case"salesforce":a=i;break;case"freshdesk":a=j;break;case"sugarcrm":a=k}return a.get().$promise.then(function(a){c.accounts=a.rows,c.element.data2&&r()})["catch"](function(a){b.show(f.instant(a.message),"danger")})},r=function(){c.configurations=_.find(c.accounts,{id:Number(c.element.data2)}).Configurations};c.changeIntegration=function(){c.element.data2="",q()},c.changeAccount=function(){c.element.data3="",r()},n||(n=a(m)),l.append(n(c,function(a){return a}))}}}}]).directive("actionBuilderStatus",["$compile","xAlert","$http","$timeout","$translate",function(a,b,c,d,e){return{restrict:"E",scope:{element:"=",form:"="},templateUrl:"app/main/template/actionBuilder/template.actionBuilderStatus.html",compile:function(b,c){var d,e;return d=b.contents().remove(),function(b,c,f){function g(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")}b.randomName=g(),b.states=[{name:"APPLICATION_STATUS_NEW",value:"NEW"},{name:"APPLICATION_STATUS_OPEN",value:"OPEN"},{name:"APPLICATION_STATUS_CLOSED",value:"CLOSED"}],e||(e=a(d)),c.append(e(b,function(a){return a}))}}}}]),angular.module("xCallyShuttleApp").factory("Ami",["$resource",function(a){return a("/api/ami/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("ChooseContactModalCtrl",["$scope","$uibModalInstance","eventId","$http","xAlert","$translate",function(a,b,c,d,e,f){a.open=function(a){b.close(a)},a.getContacts=function(){d.get("/api/contactmanager/contacts/"+c+"/checkevent").success(function(b){a.contacts=b}).error(function(a){e.show(f.instant(a.message)+"!","danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("CloseEditedTabModalCtrl",["$scope","$uibModalInstance",function(a,b){a.close=function(){b.close()},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").factory("gridOptions",["Modal","xAlert","$translate","$interval","$q","usSpinnerService",function(a,b,c,d,e,f){return{gridOptions:function(d,g,h,i,j,k){h.id=[];var l=k?"gridOptions"+k:"gridOptions",m={offset:0,limit:10};g.draggable&&(g.rowTemplate='
',g.useExternalPagination=!1,g.enablePaginationControls=!1,g.showGridFooter=!1);var n=function(a){var b=a?30*a+120:177;angular.element(document.getElementsByClassName("ui-grid")[0]).css("height",b+"px")},o=function(){return h[l].enablePaginationControls||(delete m.offset,delete m.limit),f.spin("spinner-grid"),d.get(i?_.merge(m,i):m).$promise.then(function(a){h[l].totalItems=a.count,h[l].data=a.rows,n(a.rows.length)})["catch"](function(a){console.error(a)})["finally"](function(){f.stop("spinner-grid")})};return h.deleteItem=a.confirm["delete"](function(a){var e=i?angular.copy(i):{};return _.merge(e,{id:a}),d.remove(e).$promise.then(function(){o(),b.show(c.instant("MESSAGE_WELL_DONE")+"!","success"),h.gridApi.selection.clearSelectedRows(),h.id=[]})["catch"](function(a){b.show(a.message?a.message:a.data.message,"danger")})}),h.deleteItems=a.confirm["delete"](function(){var a=i?angular.copy(i):{};return _.merge(a,{ids:h.id}),d["delete"](a).$promise.then(function(){o(),b.show(c.instant("MESSAGE_WELL_DONE")+"!","success"),h.gridApi.selection.clearSelectedRows(),h.id=[]})["catch"](function(a){b.show(a.message?a.message:a.data.message,"danger")})}),g.columnDefs.forEach(function(a){a.hasOwnProperty("displayName")||(a.displayName="APPLICATION_"+a.name.toUpperCase()),a.headerCellFilter="translate",a.hasOwnProperty("buttons")&&(a.displayName="",a.cellClass="ui-grid-vcenter",a.enableSorting=!1,a.enableFiltering=!1,a.enableColumnMenu=!1,a.cellTemplate="
",a.buttons.forEach(function(b){b.directive?a.cellTemplate+=b.directive:(a.cellTemplate+="':"",a.cellTemplate+=b.displayName||b.name?"{{'"+(b.displayName||"APPLICATION_"+b.name.toUpperCase())+"' | translate}}":"",a.cellTemplate+=" ")}),a.cellTemplate+="
",delete a.buttons)}),_.merge({enableGridMenu:!0,headerCellFilter:"translate",enableHorizontalScrollbar:0,enableVerticalScrollbar:0,enableRowSelection:!0,enableSelectAll:!0,enableFiltering:!0,showGridFooter:!0,paginationPageSizes:[10,25,50,75],paginationPageSize:10,useExternalPagination:!0,useExternalSorting:!0,useExternalFiltering:!0,multiSelect:!0,getPage:o,gridMenuTitleFilter:function(a){var b=e.defer();return b.resolve(c.instant(a)),b.promise},onRegisterApi:function(a){h.gridApi=a,h.gridApi.selection.on.rowSelectionChanged(h,function(a){a.isSelected?h.id.push(h.gridApi.grid.options.primaryKey?a.entity[h.gridApi.grid.options.primaryKey]:a.entity.id):_.pull(h.id,h.gridApi.grid.options.primaryKey?a.entity[h.gridApi.grid.options.primaryKey]:a.entity.id)}),h.gridApi.selection.on.rowSelectionChangedBatch(h,function(a){a[0].isSelected?h.id=_.union(h.id,_.map(a,h.gridApi.grid.options.primaryKey?"entity."+h.gridApi.grid.options.primaryKey:"entity.id")):_.map(a,h.gridApi.grid.options.primaryKey?"entity."+h.gridApi.grid.options.primaryKey:"entity.id").forEach(function(a){_.pull(h.id,a)})}),h.gridApi.core.on.sortChanged(h,function(a,b){0===b.length?m.order=null:m.order=b[0].name+" "+b[0].sort.direction.toUpperCase(),o()}),h.gridApi.pagination.on.paginationChanged(h,function(a,b){m.offset=(a-1)*b,m.limit=b,o()}),h.gridApi.core.on.filterChanged(h,function(){var a=this.grid;a.columns.forEach(function(a){a.filters[0].term?m[a.name]=a.filters[0].term:delete m[a.name]}),o()}),h.gridApi.draggableRows.on.rowDropped(h,function(a){a.fromIndex!==a.toIndex&&d.update(i,h[l].data).$promise.then(function(){b.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){b.show(a.message,"danger")})}),j||o()}},g)}}}]),angular.module("xCallyShuttleApp").controller("MainCtrl",["$scope","$rootScope","$translate","socket","Auth","xAlert","$uibModal","$log","$state","Contact",function(a,b,c,d,e,f,g,h,i,j){a.awesomeThings=[],a.isLoggedIn=e.isLoggedIn,a.isAdmin=e.isAdmin,a.getCurrentUser=e.getCurrentUser,a.workspaces=[],a.mainTab={active:!0},a.closeTab=function(b){if(a.workspaces[b].edited){var c=g.open({animation:!0,templateUrl:"app/main/closeEditedTab.modal.html",controller:"CloseEditedTabModalCtrl"});c.result.then(function(c){a.workspaces.splice(b,1)},function(){h.info("Modal dismissed at: "+new Date)})}else a.workspaces.splice(b,1)},a.createContact=function(b,d){return d.tags=d.tags?d.tags.join(","):void 0,j.save(d).$promise.then(function(d){a.workspaces.splice(b,1);var e=d.firstName;d.lastName&&(e+=" "+d.lastName),a.openContactTab({fullname:e,id:d.id}),f.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){f.show(a.message,"danger")})};var k=function(b){var c=g.open({animation:!0,templateUrl:"app/main/chooseContact.modal.html",controller:"ChooseContactModalCtrl",resolve:{eventId:function(){return b.id}}});c.result.then(function(c){c?a.openContactTab(c):a.newContact(b)},function(){h.info("Modal dismissed at: "+new Date)})};a.updateContact=function(b,d){var e=angular.copy(d);return e.tags=e.tags?e.tags.join(","):void 0,e.CompanyId||(e.CompanyId=null),j.update({id:e.id},e).$promise.then(function(){a.workspaces[b].edited=!1,f.show(c.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){f.show(c.instant(a.message)+"!","danger")})},d.socket.on("report_integration:contactmanager",function(a){console.log("choosecontact"),k(a)}),a.openContactTab=function(b){var c=_.find(a.workspaces,{contactID:b.id});if(c)c.active=!0;else{var d=b.firstName;b.lastName&&(d+=" "+b.lastName),a.workspaces.push({name:d,type:"contact",contactID:b.id,active:!0,eventData:b.uniqueid?b:null})}},a.openJscriptyTab=function(b){a.workspaces.push({name:b.name,type:"jscripty",active:!0,data:b})},a.newContact=function(b){a.workspaces.push({name:"New Contact",type:"newContact",active:!0,data:b||null,eventData:b&&b.uniqueid?b:""})},a.$on("$viewContentLoaded",function(){Metronic.init()}),b.language=c.use(),a.changeLanguage=function(a){c.use(a).then(function(a){b.language=a,("main.jscripty.projects.view"===i.current.name||"main.square.projects.view"===i.current.name)&&i.go(i.current,{},{reload:!0})})["catch"](function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").directive("ngSpinnerBar",["$rootScope",function(a){return{link:function(b,c){c.addClass("hide"),a.$on("$stateChangeStart",function(){"spinner-page"===c[0].id&&c.removeClass("hide")}),a.$on("$stateChangeSuccess",function(){"spinner-page"===c[0].id&&(c.addClass("hide"),$("body").removeClass("page-on-load"),Layout.setSidebarMenuActiveLink("match"),setTimeout(function(){Metronic.scrollTop()},1e3))}),a.$on("$spinnerStart",function(){"spinner-request"===c[0].id&&c.removeClass("hide")}),a.$on("$spinnerStop",function(){"spinner-request"===c[0].id&&c.addClass("hide")}),a.$on("$stateNotFound",function(){"spinner-page"===c[0].id&&c.addClass("hide")}),a.$on("$stateChangeError",function(){"spinner-page"===c[0].id&&c.addClass("hide")})}}}]).directive("a",function(){return{restrict:"E",link:function(a,b,c){(c.ngClick||""===c.href||"#"===c.href)&&b.on("click",function(a){a.preventDefault()})}}}).directive("nxEqual",function(){return{require:"ngModel",link:function(a,b,c,d){return c.nxEqual?(a.$watch(c.nxEqual,function(a){d.$setValidity("nxEqual",a===d.$viewValue)}),void d.$parsers.push(function(b){var e=b===a.$eval(c.nxEqual);return d.$setValidity("nxEqual",e),e?b:void 0})):void console.error("nxEqual expects a model as an argument!")}}}).directive("ngEnter",function(){return function(a,b,c){b.bind("keydown keypress",function(b){13===b.which&&(a.$apply(function(){a.$eval(c.ngEnter)}),b.preventDefault())})}}).directive("dropdownMenuHover",function(){return{link:function(a,b){b.dropdownHover()}}}).directive("uiSelectRequired",function(){return{require:"ngModel",link:function(a,b,c,d){d.$validators.uiSelectRequired=function(a){return a&&a.length}}}}).directive("rpattern",function(){return{restrict:"A",require:"ngModel",link:function(a,b,c,d){function e(a,b){return null==b||""===b||!h||a.test(b)?(d.$setValidity("pattern",!0),b):void d.$setValidity("pattern",!1)}var f,g=c.rpattern,h=!0;g&&(g.match(/^\/(.*)\/$/)?(g=new RegExp(g.substr(1,g.length-2)),f=function(a){return e(g,a)}):f=function(b){var c=a.$eval(g);if(!c||!c.test)throw new Error("Expected "+g+" to be a RegExp but was "+c);return e(c,b)}),d.$formatters.push(f),d.$parsers.push(f),c.$observe("required",function(a){h=a,f(d.$viewValue)})}}}).directive("conditionBuilder",["$compile","xAlert","$timeout",function(a,b,c){return{restrict:"E",scope:{element:"=",serviceindex:"=",service:"=",form:"="},templateUrl:"app/main/template/template.conditionBuilder.html",compile:function(d,e){var f,g;return f=d.contents().remove(),function(d,e,h){function i(a){var c=_.find(d.service.services[d.serviceindex].conditions,{value:a});if(c)if(d.elementType=c.type,c.arr)d.values=c.arr;else if(c.resource)return c.resource.get().$promise.then(function(a){d.values=_.map(a.rows,function(a){return{name:a[c.resValue],value:a[c.resValue]}})})["catch"](function(a){b.show($translate.instant(a.message),"danger")})}function j(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")}d._=_,d.randomName=j(),c(function(){d.element.field&&i(d.element.field)}),d.checkCondition=function(a){d.element.value="",d.element.operator="",i(a)},g||(g=a(f)),e.append(g(d,function(a){return a}))}}}}]).directive("newContact",["$compile","xAlert","socket","$translate","$timeout","Service","Tag","Company",function(a,b,c,d,e,f,g,h){return{restrict:"E",scope:{workspace:"=",index:"=",submit:"&onSubmit"},templateUrl:"app/main/template/template.contactTab.html",compile:function(a,i){return function(a,i,j){function k(){a.$watch("contact",function(b,c){angular.equals(b,c)||(a.workspace.edited=!0)},!0)}a.forms={general:{}},a.firstLoad=!0,a.detail={tab:"main"},a.contact={},a.submitButtonLabel=d.instant("APPLICATION_CONFIRM"),a.init=function(){a.workspace.data&&(a.contact.firstName=a.workspace.data.calleridname?a.workspace.data.calleridname:a.workspace.data.messageId?a.workspace.data.messageId:a.workspace.data.uniqueid?a.workspace.data.uniqueid:"",a.workspace.data.calleridnum&&(a.contact.phone=a.workspace.data.calleridnum),a.workspace.data.from&&(a.contact.email=a.workspace.data.from)),a.getTags(),a.getCompanies(),a.getServices()},a.getServices=function(){return f.get().$promise.then(function(b){a.services=b.rows,c.syncUpdates("service",a.services),a.contact.ServiceId=1,a.getCustomFields()})["catch"](function(a){b.show(d.instant(a.message)+"!","danger")})},a.getCustomFields=function(){return f.get({serviceId:a.contact.ServiceId,controller:"customfields"}).$promise.then(function(b){a.customFields=b.rows,a.customFields.forEach(function(a){a.values=JSON.parse(a.values)}),c.socket.on("custom_field:remove",function(b){_.remove(a.customFields,function(a){return b.id==a.id})}),c.socket.on("custom_field:save",function(b){if(b.ServiceId===a.contact.ServiceId){var c=_.find(a.customFields,{id:b.id});c||("string"==typeof b.values&&(b.values=JSON.parse(b.values)),a.customFields.push(b))}}),!a.firstLoad||a.workspace.data?(a.workspace.edited=!0,a.firstLoad=!1):(a.firstLoad=!1,k())})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getTags=function(){return g.get().$promise.then(function(b){a.tags=_.map(b.rows,"name")})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getCompanies=function(){return h.get().$promise.then(function(b){a.companies=b.rows,c.syncUpdates("company",a.companies)})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},e(function(){a.init()})}}}}]).directive("contact",["$compile","xAlert","socket","$timeout","Service","Tag","Company","Contact","$translate","gridOptions",function(a,b,c,d,e,f,g,h,i,j){return{restrict:"E",scope:{workspace:"=",index:"=",submit:"&onSubmit"},templateUrl:"app/main/template/template.contactTab.html",compile:function(a,k){return function(a,k,l){function m(b){var c={exporterCsvFilename:b+".csv",columnDefs:[{name:a.columns[a.log[b].show][a.log[b].detail].indexes[0],displayName:a.columns[a.log[b].show][a.log[b].detail].header[0],headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:a.columns[a.log[b].show][a.log[b].detail].indexes[1],displayName:a.columns[a.log[b].show][a.log[b].detail].header[1],headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1},{name:a.columns[a.log[b].show][a.log[b].detail].indexes[2],displayName:a.columns[a.log[b].show][a.log[b].detail].header[2],headerCellFilter:"translate",enableSorting:!1,enableColumnMenu:!1}]};a["gridOptions"+b]=j.gridOptions(h,c,a,_.merge({id:a.workspace.contactID,controller:"log",logType:b},a.log[b]),!0,b),a["gridOptions"+b].getPage()}a.moment=moment,a.submitButtonLabel=i.instant("APPLICATION_UPDATE"),a.forms={general:{}},a.detail={tab:"main"},a.log={journal:{show:"phone",type:"inbound",detail:"general"},history:{show:"phone",type:"inbound",detail:"general"}},a.columns={phone:{general:{header:["APPLICATION_SOURCE","APPLICATION_DESTINATION","APPLICATION_DATE"], -indexes:["source","destination","createdAt"]},queue:{header:["APPLICATION_CALLERID","APPLICATION_QUEUE","APPLICATION_DATE"],indexes:["calleridnum","queue","createdAt"]},agent:{header:["APPLICATION_AGENT","APPLICATION_QUEUE","APPLICATION_DATE"],indexes:["membername","queue","agentcalledAt"]}},email:{general:{header:["APPLICATION_FROM","APPLICATION_TO","APPLICATION_DATE"],indexes:["from","to","createdAt"]}}},a.updateLog=function(b,c,d,e){c&&(a.log[b].show=c),d&&(a.log[b].detail=d),e&&(a.log[b].type=e),m(b)},a.getContact=function(){return h.get({id:a.workspace.contactID}).$promise.then(function(b){b.tags=b.tags?b.tags.split(","):[],a.contact=b,a.getCustomFields(b.ServiceId),a.updateLog("journal"),a.updateLog("history")})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getTags=function(){return f.get().$promise.then(function(b){a.tags=_.map(b.rows,"name")})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getCompanies=function(){return g.get().$promise.then(function(b){a.companies=b.rows,c.syncUpdates("company",a.companies)})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},a.getCustomFields=function(d){return e.get({serviceId:d,controller:"customfields"}).$promise.then(function(b){a.customFields=b.rows,a.customFields.forEach(function(a){a.values=JSON.parse(a.values)}),c.socket.on("custom_field:remove",function(b){_.remove(a.customFields,function(a){return b.id==a.id})}),c.socket.on("custom_field:save",function(b){if(b.ServiceId===d){var c=_.find(a.customFields,{id:b.id});c||("string"==typeof b.values&&(b.values=JSON.parse(b.values)),a.customFields.push(b))}})})["catch"](function(a){console.error(a),b.show(a.message,"danger")})},d(function(){a.getTags(),a.getCompanies(),a.getContact()})}}}}]).directive("jscripty",["$compile","xAlert","$http","socket",function(a,b,c,d){return{restrict:"E",scope:{workspace:"=",index:"=",submit:"&onSubmit"},templateUrl:"app/main/template/template.jscriptyTab.html",compile:function(a,d){return function(a,d,e){a.count=0,a.questions=[];var f=0,g=a.workspace.data.id;c.get("/api/jscripty/projects/"+g+"/download").success(function(b){if(b){c.post("/api/jscripty/projects/"+g+"/sessions",{projectId:g,status:"started"}).success(function(a){f=a.session_id,console.log(a)});var d=mxUtils.parseXml(b),e=new mxCodec(d);a.decObj=e.decode(d.documentElement);a.questions[a.count]=a.currentQuestion=_.find(a.decObj.cells,function(a){return a.vertex&&"start"==a.value.nodeName})}else console.log("No project published!"),alert("No project published!"),a.submit({index:a.index})}),a.next=function(b,c){a.currentQuestion.answer&&a.currentQuestion.answer!=c&&(a.questions=_.take(a.questions,a.count+1)),a.currentQuestion.answer=c,a.questions[a.count]=a.currentQuestion;var d=[];_.forEach(b.edges,function(a,c){if(a.source.id==b.id&&a.value){var e=a.value.split(",");e.length>1&&(_.forEach(e,function(c,d){var e=Object.create(a);e.setValue(c),b.edges.push(e)}),d.push(a))}}),_.forEach(d,function(a){_.remove(b.edges,function(b){return b.value==a.value&&b.id==a.id})}),a.currentQuestion=b,a.count++,a.questions[a.count]=b,a.saveQuestions()},a.end=function(){var d="completed";if("end"!=a.questions[a.questions.length-1].value.nodeName){var d="incomplete";a.saveQuestions()}c.put("/api/jscripty/projects/"+g+"/sessions/"+f,{status:d,completedAt:Date(),last_question_id:a.currentQuestion.id}).success(function(c){b.show("Project Ended","success"),a.submit({index:a.index})})},a.back=function(){a.count--,a.currentQuestion=a.questions[a.count]},a.setCurrentQuestion=function(b){a.count=b,a.currentQuestion=a.questions[a.count]},a.saveQuestions=function(){var b=[],d=[];_.forEach(a.questions,function(a,c){a.children&&_.forEach(a.children,function(a,b){d[b]={input_id:a.id,input_type:a.getAttribute("type",""),input_label:a.getAttribute("label",""),input_value:"checkbox"!=a.getAttribute("type","")||a.answer?a.answer:"Not selected"}}),b[c]={sessionId:f,projectId:g,question_id:a.id,question_type:a.value.nodeName,question_label:a.getAttribute("label",""),question_text:a.getAttribute("question",""),question_other_label:a.getAttribute("other"),question_other_answer:a.otheranswer,question_answer:a.answer,ReportJscriptyInputs:d},d=[]}),c.post("/api/jscripty/projects/"+g+"/sessions/"+f+"/questions/",b).success(function(a){})}}}}}]).directive("reportBuilder",["$compile",function(a){return{restrict:"E",scope:{group:"=",fields:"=",forms:"=",firstCall:"="},templateUrl:"app/main/template/template.reportBuilderView.html",compile:function(b,c){var d,e;return d=b.contents().remove(),function(b,c,f){b.operators=[{name:"AND"},{name:"OR"}],b.conditions=[{name:"="},{name:"!="},{name:"<"},{name:"<="},{name:">"},{name:">="},{name:"LIKE"}],b.addCondition=function(){b.group.rules.push({condition:"=",field:"",value:""})},b.removeCondition=function(a){b.group.rules.splice(a,1)},b.addGroup=function(){b.group.rules.push({group:{operator:"AND",rules:[{condition:"=",field:"",value:""}]}})},b.randomName=function(a,b){var c=[];for(a=a||5,b=b||"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";--a;)c.push(b.charAt(Math.floor(Math.random()*b.length)));return c.join("")},b.removeGroup=function(){b.$parent.group&&b.$parent.group.rules.splice(b.$parent.$index,1)},e||(e=a(d)),c.append(e(b,function(a){return a}))}}}}]).directive("dynamicName",["$compile",function(a){return{restrict:"A",terminal:!0,priority:1e3,link:function(b,c,d){c.attr("name",b.$eval(d.dynamicName)),c.removeAttr("dynamic-name"),a(c)(b)}}}]).directive("onReadFile",["$parse",function(a){return{restrict:"A",scope:!1,link:function(b,c,d){var e=a(d.onReadFile);c.on("change",function(a){var c=new FileReader;c.onload=function(a){b.$apply(function(){e(b,{$fileContent:a.target.result})})},c.readAsText((a.srcElement||a.target).files[0])})}}}]).directive("motionFileDownload",["xAlert","$translate","$timeout","$location","FileSaver","$compile",function(a,b,c,d,e,f){return{restrict:"E",template:'',scope:{mimetype:"=",filename:"=",resource:"=",params:"=",btnclass:"@",btncontent:"@",tooltiptext:"@"},link:function(c,d,f){var g=d.children()[0];c.$on("download-start",function(){$(g).attr("disabled","disabled")}),c.$on("downloaded",function(a,b){var d=base64ToBlob(b,c.mimetype);e.saveAs(d,c.filename),$(g).attr("disabled",!1)}),c.download=function(){return c.$emit("download-start"),c.resource.get(c.params).$promise.then(function(a){c.$emit("downloaded",a.downloadString)})["catch"](function(d){a.show(b.instant(d.translatedMessage||d.data.translatedMessage||d.message||d.data.message),"danger"),c.download=function(){}})}}}}]).directive("audioFileDownload",["xAlert","$translate","$sce",function(a,b,c){return{restrict:"E",template:'',scope:{resource:"=",params:"="},link:function(d,e,f){var g=e.children()[0];d.$on("download-start",function(a,b){$(g).attr("disabled","disabled").html(' Loading...')}),d.$on("downloaded",function(a,b){var d=new Audio(c.trustAsResourceUrl("data:audio/ogg;base64,"+b));d.controls=!0,$(g).remove(),e.append(d),d.play()}),d.$on("error",function(a,b){$(g).removeClass("blue-stripe").addClass("red-stripe").html(' Error!')}),d.download=function(){return d.$emit("download-start"),d.resource.get(d.params).$promise.then(function(a){d.$emit("downloaded",a.downloadString)})["catch"](function(c){a.show(b.instant(c.translatedMessage||c.data.translatedMessage||c.message||c.data.message),"danger")})}}}}]).directive("uiRequired",function(){return{require:"ngModel",link:function(a,b,c,d){d.$validators.required=function(a,b){return!(b&&0===b.length&&"true"===c.uiRequired)},c.$observe("uiRequired",function(){d.$setValidity("required",!("true"===c.uiRequired&&d.$viewValue&&0===d.$viewValue.length))})}}}),angular.module("xCallyShuttleApp").filter("propsFilter",function(){return function(a,b){var c=[];return angular.isArray(a)?a.forEach(function(a){for(var d=!1,e=Object.keys(b),f=0;f=0}),b}}).filter("freshdesk",function(){var a=["requester","subject","agent","description"];return function(b){return _.remove(b,function(b){return a.indexOf(b.ticket_field.name)>=0}),b}}).filter("zendesk",function(){var a=["subject","assignee","description"];return function(b){return _.remove(b,function(b){return a.indexOf(b.type)>=0}),b}}),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main",{"abstract":!0,templateUrl:"app/main/main.html",controller:"MainCtrl",resolve:{authorization:["$q","Auth","$state","$timeout","$location",function(a,b,c,d,e){return b.getToken()?a.when():(d(function(){e.path("/login")}),a.reject())}],deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css","assets/plugins/mxgraph/js/mxClient.js"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("xAlert",["$translate","Notification",function(a,b){return{show:function(c,d){switch(d){case"success":b.success({message:c,title:' '+a.instant("MESSAGE_SUCCESS")+"!",delay:5e3});break;case"info":b.info({message:c,title:' '+a.instant("MESSAGE_INFO")+"!",delay:5e3});break;case"danger":b.error({message:c,title:' '+a.instant("MESSAGE_ERROR")+"!",delay:1e4});break;case"warning":b.warning({message:c,title:' '+a.instant("MESSAGE_WARNING")+"!",delay:1e4});break;default:b.info(c)}}}}]).factory("stResource",["$q","$filter","$timeout","$rootScope","$http","$translate","xAlert",function(a,b,c,d,e,f,g){return{getPage:function(b){var c={page:Math.ceil(b.pagination.start/b.pagination.number),per_page:b.pagination.number};b.sort.predicate&&(c.sort_by=b.sort.predicate,c.sort_order=b.sort.reverse?"DESC":"ASC"),_.forIn(b.search.predicateObject,function(a,b){c[b]=a}),b.search.params&&(c.clientQuery={},_.forIn(b.search.params,function(a,b){c.clientQuery[b]=a})),d.$broadcast("$spinnerStart"),e.get(b.url,{params:c}).success(function(a){h.resolve(a),d.$broadcast("$spinnerStop")}).error(function(a){g.show(f.instant(a.message),"danger"),d.$broadcast("$spinnerStop")});var h=a.defer();return h.promise}}}]),angular.module("xCallyShuttleApp").factory("Widget",["$resource",function(a){return a("/api/widgets/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("MarketCtrl",["$scope","$http","$translate","socket","xAlert","Modal","$timeout",function(a,b,c,d,e,f,g){function h(a,b){return Math.floor(Math.random()*(b-a+1))+a}a.initView=function(){b.get("/api/integrations").success(function(b){a.integrations=b.rows,a.groupedIntegration=_.chunk(a.integrations,4),d.syncUpdates("integration",a.integrations,function(){a.groupedIntegration=_.chunk(a.integrations,4)})}).error(function(a){e.show(a.message,"danger")})},a.isProgressing=!1,a.$on("$destroy",function(){d.unsyncUpdates("integration")}),a.installIntegration=function(d){a.status="Downloading",a.percentage=h(1,50),a.isProgressing=!0,d.downloading=!0,b.put("/api/integrations/"+d.id,{active:!0}).success(function(){g(function(){a.percentage=h(51,99),a.status="Installing"},2500),g(function(){a.percentage=100,a.isProgressing=!1,a.status="Completed!",d.downloading=!1,e.show(c.instant("MESSAGE_WELL_DONE")+".","success")},5e3)}).error(function(){d.downloading=!1,a.percentage=0,a.isProgressing=!1,e.show(c.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.uninstallIntegration=function(d){a.status="Uninstalling",a.percentage=h(1,99),a.isProgressing=!0,d.downloading=!0,b.put("/api/integrations/"+d.id,{active:!1}).success(function(){g(function(){a.percentage=100,a.isProgressing=!1,a.status="Completed!",d.downloading=!1,e.show(c.instant("MESSAGE_WELL_DONE")+".","success")},5e3)}).error(function(){d.downloading=!1,a.percentage=0,a.isProgressing=!1,e.show(c.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.market",{url:"/market",templateUrl:"app/market/market.html",controller:"MarketCtrl",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("MotionbarCtrl",["$scope","$stateParams","$cookieStore","settings","Auth",function(a,b,c,d,e){e.loginWithToken(b.token,b.userId,b.name),a.getCurrentUser=e.getCurrentUser,d.layout.pageQuickSidebarOpened=!0}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("motionbar",{url:"/motionbar",template:"
","abstract":!0}).state("motionbar.chat",{url:"/chat?token&userId&name",templateUrl:"app/motionbar/motionbar.chat.html",controller:"MotionbarCtrl"})}]),angular.module("xCallyShuttleApp").controller("SalesforceListCtrl",["$scope","$http","$rootScope","xAlert","$translate","socket","Modal","stResource",function(a,b,c,d,e,f,g,h){a.conf={accountsByPage:{name:"10",value:10}},a.accountsByPage=[{name:"10",value:10},{name:"25",value:25},{name:"50",value:50},{name:"All",value:0}],a.accounts={checked:[]},a.check=function(b,c){c?a.accounts.checked=angular.copy(_.map(a.displayedSalesforceAccounts,"id")):a.accounts.checked=[]},a.getAccounts=function(b){return _.map(a.displayedSalesforceAccounts,function(a){var c={};return b.forEach(function(b){c[b]=a[b]}),c})},a.initList=function(b){f.unsyncUpdates("salesforce_account"),b.url="/api/salesforce/accounts",h.getPage(b).then(function(d){a.displayedSalesforceAccounts=d.rows,b.pagination.numberOfPages=d.total_pages,c.updateTableConfig(a.accountsByPage,a.displayedSalesforceAccounts.length),c.updateTableConfig(a.conf.accountsByPage,a.displayedSalesforceAccounts.length)}),f.socket.on("salesforce_account:save",function(){a.initList(b)}),f.socket.on("salesforce_account:remove",function(c){a.accounts.checked=_.without(a.accounts.checked,c.id),a.initList(b)})},a.deleteItem=g.confirm["delete"](function(a){b["delete"]("/api/salesforce/accounts/"+a).success(function(){d.show(e.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.deleteItems=g.confirm["delete"](function(){b["delete"]("/api/salesforce/accounts",{params:{id:a.accounts.checked}}).success(function(){d.show(e.instant("MESSAGE_WELL_DONE"),"success")}).error(function(a){d.show(e.instant(a.message),"danger")})}),a.checkAccount=function(a){b.get("/api/salesforce/accounts/"+a+"/check").then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.salesforce.list",{url:"/list",templateUrl:"app/salesforce/list/list.html",controller:"SalesforceListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.salesforce",{url:"/salesforce",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("SalesforceAccount",["$resource",function(a){return a("/api/salesforce/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("SalesforceViewCtrl",["$scope","$http","$stateParams","$translate","$location","WizardHandler","socket","xAlert","Modal","$filter",function(a,b,c,d,e,f,g,h,i,j){a.$stateParams=c,a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:500,scrollInertia:0},a.initConfiguration=function(){a.formsConfiguration={},a.configuration={}},a.goNext=function(){f.wizard().next()},a.formValidation=function(a){return a},a.$on("$destroy",function(){g.unsyncUpdates("salesforce_configuration"),g.unsyncUpdates("salesforce_field")}),a.initView=function(){b.get("/api/salesforce/accounts/"+c.id).success(function(b){a.account=b}).error(function(a){h.show(a.message,"danger")})},a.updateItem=function(){b.put("/api/salesforce/accounts/"+c.id,a.account).success(function(){h.show(d.instant("MESSAGE_WELL_DONE")+".","success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getConfigurations=function(){b.get("/api/salesforce/configurations",{params:{AccountId:c.id}}).success(function(b){a.configurations=b,g.socket.on("salesforce_configuration:remove",function(b){_.remove(a.configurations,{id:b.id})})}).error(function(a){h.show(a.message,"danger")})},a.deleteConfiguration=i.confirm["delete"](function(a){b["delete"]("api/salesforce/configurations/"+a).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.createConfiguration=function(){a.configuration.AccountId=c.id,b.post("api/salesforce/configurations",a.configuration).success(function(a){e.path("salesforce/view/"+c.id+"/configurations/settings/"+a.id)}).error(function(){h.show("Something went wrong!","danger")})},a.fieldType=["string","variable"],a.descFieldType=["string","key_value"],a.getFields=function(){b.get("/api/salesforce/accounts/"+c.id+"/fields").success(function(b){a.accountFields=_.sortByOrder(j("salesforce")(b),"name","asc")}).error(function(a){h.show(a.message,"danger")})},a.getConfiguration=function(){b.get("/api/salesforce/configurations/"+c.configurationId).success(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,g.socket.on("salesforce_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})}).error(function(a){h.show(a.message,"danger")})},a.getVariables=function(){b.get("/api/variables").success(function(b){a.variables=b.rows}).error(function(a){h.show(a.message,"danger")})},a.removeItem=function(a){b["delete"]("api/salesforce/fields/"+a.id).success(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.addItemSubject=function(){var d={type:"string",content:""};b.post("/api/salesforce/configurations/"+c.configurationId+"/subject",d).success(function(b){a.subjectConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.addItemDescription=function(){var d={type:"string",content:""};b.post("/api/salesforce/configurations/"+c.configurationId+"/description",d).success(function(b){a.descriptionConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.addItemField=function(){var d={content:""};b.post("/api/salesforce/configurations/"+c.configurationId+"/field",d).success(function(b){a.fieldConfig.push(b)}).error(function(){h.show("Something went wrong!","danger")})},a.updateField=function(a){b.put("/api/salesforce/fields/"+a.id,a).success(function(){}).error(function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.changeType=function(b){"variable"===b.type?b.content="":"string"===b.type&&(b.VariableId=null),a.updateField(b)},a.changeDescType=function(b){"key_value"===b.type?(b.content="","string"===b.keyType?b.VariableId=null:"variable"===b.keyType&&(b.keyContent="")):"string"===b.type&&(b.VariableId=null,b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){b.content="",a.updateField(b)},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"name",b);if(c)switch(c.type){case"picklist":return c.picklistValues;default:return}}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.salesforce.view",{url:"/view/:id",templateUrl:"app/salesforce/view/view.html",controller:"SalesforceViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.salesforce.view.account",{url:"/account",templateUrl:"app/salesforce/view/view.account.html"}).state("main.salesforce.view.configurations",{url:"/configurations",templateUrl:"app/salesforce/view/view.configurations.html"}).state("main.salesforce.view.configurations.settings",{url:"/settings/:configurationId",templateUrl:"app/salesforce/view/view.configurationSettings.html",controller:"SalesforceViewCtrl"}).state("main.salesforce.view.configuration",{url:"/configuration",templateUrl:"app/salesforce/view/view.configuration.html"})}]),angular.module("xCallyShuttleApp").controller("SalesforceWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={}},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){console.log(a.item),b.post("api/salesforce/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/salesforce/list")}).error(function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.salesforce.wizard",{url:"/wizard",templateUrl:"app/salesforce/wizard/wizard.html",controller:"SalesforceWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("License",["$resource",function(a){return a("/api/licenses/:id/:controller",{id:"@id"},{request:{method:"POST",params:{id:"request"}}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.license",{url:"/license",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("LicenseViewCtrl",["$scope","$rootScope","$translate","License","xAlert",function(a,b,c,d,e){a.initView=function(){d.get(function(b){a.item=b.license})},a.submitRequest=function(){d.request(a.item,function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")},function(a){switch(a.status){case 304:e.show(a.statusText,"info");break;default:e.show(a.statusText,"danger")}})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.license.view",{url:"/view",templateUrl:"app/setting/license/view/view.html",controller:"LicenseViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/pricing-tables.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting",{url:"/setting",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("Setting",["$resource",function(a){return a("/api/settings/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("Smtp",["$resource",function(a){return a("/api/mail/servers/out/:id/:controller",{id:"@id"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.smtp",{url:"/smtp",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("SmtpViewCtrl",["$scope","$stateParams","$translate","MailServerOut","xAlert","usSpinnerService",function(a,b,c,d,e,f){a.initView=function(){a.item={},d.get({id:"service"}).$promise.then(function(b){a.item=b})["catch"](function(a){e.show(a.message,"danger")})},a.updateItem=function(){return a.item.id?d.update({id:a.item.id},a.item).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.message,"danger")}):(a.item.service=!0,d.save(a.item).$promise.then(function(b){a.item=b,e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.message,"danger")}))},a.test=function(){return f.spin("spinner-grid"),d.test({id:a.item.id,controller:"test"}).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})["finally"](function(){f.stop("spinner-grid")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.smtp.view",{url:"/view",templateUrl:"app/setting/smtp/view/view.html",controller:"SmtpViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("UpdateListCtrl",["$scope","gridOptions","$uibModal","$location","Update",function(a,b,c,d,e){a.initCounter=function(){a.$on("timer-stopped",function(a,b){console.log("Timer Stopped - data = ",b),d.path("/dashboard/voice")})},a.initView=function(){var c={exporterCsvFilename:"updates.csv",enableFiltering:!1,enableSorting:!1,enablePaginationControls:!1,enableSelectAll:!1,columnDefs:[{name:"message"},{width:125,name:"version",cellClass:"text-center ui-grid-vcenter"},{width:125,name:"createdAt",displayName:"APPLICATION_UPDATED_AT",cellClass:"text-center ui-grid-vcenter",cellTemplate:'
'}]};a.gridOptions=b.gridOptions(e,c,a)},a.pull=function(){c.open({animation:!0,templateUrl:"app/setting/update/list/list.pull.html",controller:"UpdateListPullCtrl"})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.updates.list",{url:"/list",templateUrl:"app/setting/update/list/list.html",controller:"UpdateListCtrl"}).state("main.setting.updates.landing",{url:"/landing",templateUrl:"app/setting/update/list/landing.html",controller:"UpdateListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/error.css"]}])}]}})}]),angular.module("xCallyShuttleApp").controller("UpdateListPullCtrl",["$scope","$uibModalInstance","$translate","$location","Update","xAlert",function(a,b,c,d,e,f){a.modal={dismissable:!0,title:"Confirm Checkout",html:"Are you sure you want to checkout?",buttons:[{classes:"btn btn-success",text:"Checkout",click:function(){return e.pull().$promise.then(function(){console.log("success"),d.path("/setting/updates/landing")})["catch"](function(a){console.error("err",a),f.show(c.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})["finally"](function(){b.dismiss("close")})}},{classes:"btn default",text:"Cancel",click:function(){b.dismiss("cancel")}}]}}]),angular.module("xCallyShuttleApp").factory("Update",["$resource",function(a){return a("/api/updates/:id/:controller",{id:"@id"},{pull:{method:"GET",params:{id:"pull"}}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.setting.updates",{url:"/updates",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("SquareOdbcListCtrl",["$scope","$uibModal","$translate","SquareOdbc","gridOptions","xAlert",function(a,b,c,d,e,f){a.initView=function(){var b={exporterCsvFilename:"odbc.csv",columnDefs:[{name:"name"},{name:"dsn",displayName:"APPLICATION_ODBC"},{name:"description"},{name:"action",width:250,buttons:[{"class":"blue-hoki",href:"/square/odbc/view/{{row.entity.id}}/settings",name:"settings"},{"class":"green-jungle",name:"check",displayName:"APPLICATION_CHECK_CONNECTION",onClick:"grid.appScope.checkConnection(row.entity.id)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=e.gridOptions(d,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/square/odbc/list/list.create.modal.html",controller:"SquareOdbcListCreateCtrl"});c.result.then(function(){a.gridOptions.getPage()})},a.checkConnection=function(a){return d.get({id:a,controller:"check"}).$promise.then(function(){f.show(c.instant("MESSAGE_CONNECTION_VERIFIED"),"success")})["catch"](function(){f.show(c.instant("MESSAGE_CONNECTION_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").controller("SquareOdbcListCreateCtrl",["$scope","$translate","$uibModalInstance","SquareOdbc","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.item.dsn||(a.item.dsn="DRIVER=MySQL;SERVER=127.0.0.1;UID=xcall;PWD=password;DATABASE=motion"),a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.odbc.list",{url:"/list",templateUrl:"app/square/odbc/list/list.html",controller:"SquareOdbcListCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.odbc",{url:"/odbc",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("SquareOdbc",["$resource",function(a){return a("/api/square/odbc/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("SquareOdbcViewCtrl",["$scope","$translate","$stateParams","SquareOdbc","xAlert",function(a,b,c,d,e){a.odbc={},a.getOdbc=function(){return d.get({id:c.id}).$promise.then(function(b){a.odbc=b})["catch"](function(a){e.show(a.data.message,"danger")})},a.updateOdbc=function(){var f=angular.copy(a.odbc);return d.update({id:c.id},f).$promise.then(function(){e.show(b.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.odbc.view",{url:"/view/:id",templateUrl:"app/square/odbc/view/view.html",controller:"SquareOdbcViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.square.odbc.view.settings",{url:"/settings",templateUrl:"app/square/odbc/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("SquareProjectListCtrl",["$scope","$uibModal","SquareProject","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"projects.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/square/projects/view/{{row.entity.id}}",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){ -var c=b.open({animation:!0,templateUrl:"app/square/project/list/list.create.modal.html",controller:"SquareProjectListCreateCtrl"});c.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("SquareProjectListCreateCtrl",["$scope","$translate","$uibModalInstance","SquareProject","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.projects.list",{url:"/list",templateUrl:"app/square/project/list/list.html",controller:"SquareProjectListCtrl",authenticate:!0})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.projects",{url:"/projects",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").factory("SquareProject",["$resource",function(a){return a("/api/square/projects/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("SquareProjectViewCtrl",["$scope","$stateParams","Auth","xAlert","SquareProject",function(a,b,c,d,e){a.squareProject={},a.getProject=function(){return e.get({id:b.id}).$promise.then(function(b){a.squareProject=b,angular.element(document).ready(function(){window.onerror=function(a,b,c){try{if(null!==a&&-1!==a.indexOf("Script error."));else{var e=new Image;e.src="assets/plugins/mxgraph/images/1x1.png?msg="+encodeURIComponent(a)+"&url="+encodeURIComponent(b)+"&lnum="+encodeURIComponent(c)}}catch(f){d.show(f,"danger")}},b.token=c.getToken();var a=new EditorUi(new Editor);a.openString(b.preproduction,b.name,b),a.editor.graphChangeListener=function(a,b){var c=b.properties.rtChange||!1;c||(this.modified=!0)}})})["catch"](function(a){d.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square.projects.view",{url:"/view/:id",templateUrl:"app/square/project/view/view.html",controller:"SquareProjectViewCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",serie:!0,cache:!1,files:["assets/plugins/mxgraph/css/common.css","assets/plugins/mxgraph/css/explorer.css","assets/plugins/mxgraph/styles/grapheditor.css","assets/plugins/mxgraph/styles/custom.css","assets/plugins/square/js/custom.js","assets/plugins/mxgraph/js/mxClient.js","assets/plugins/square/js/Editor.js","assets/plugins/square/js/Graph.js","assets/plugins/square/js/EditorUi.js","assets/plugins/square/js/Actions.js","assets/plugins/square/js/Menus.js","assets/plugins/square/js/Sidebar.js","assets/plugins/square/js/Toolbar.js","assets/plugins/square/js/Dialogs.js"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.square",{url:"/square",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("Agent",["$resource",function(a){return a("/api/agents/:id/:controller",{id:"@id"},{changePassword:{method:"PUT",params:{controller:"password"}},update:{method:"PUT"},patch:{method:"PATCH"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.agents",{url:"/agents",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AgentListCtrl",["$scope","Agent","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"agents.csv",columnDefs:[{name:"fullname"},{name:"name",displayName:"APPLICATION_USERNAME"},{name:"internal"},{name:"email"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/staff/agents/view/{{row.entity.id}}/account",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.fullname, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.agents.list",{url:"/list",templateUrl:"app/staff/agent/list/list.html",controller:"AgentListCtrl",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("AgentViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$cookieStore","Agent","FileUploader","Auth","User",function(a,b,c,d,e,f,g,h,i,j){a.Auth=i,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.updatePassword=function(){var b={newPassword:a.agent.newPwd};return i.isAdmin()?b.id=e.id:b.oldPassword=a.agent.currentPwd,j.changePassword(b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.message,"danger")})};var k=a.uploader=new h({url:"api/users/"+e.id+"/avatar",queueLimit:1,withCredentials:!0,headers:{Authorization:"Bearer "+f.get("token")}});k.filters.push({name:"imageFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|jpg|png|jpeg|".indexOf(b)}}),k.onSuccessItem=function(b,e){a.agent.userpic=e.userpic,a.agent.id===i.getCurrentUser().id&&(i.getCurrentUser().userpic=e.userpic),c.show(d.instant("MESSAGE_WELL_DONE"),"success")},k.onErrorItem=function(){c.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")},k.onCompleteAll=function(){k.clearQueue()},a.initView=function(){return g.get({id:e.id}).$promise.then(function(b){a.agent=b,a.agent.transport=a.agent.transport?a.agent.transport.split(","):[],a.agent.allow=a.agent.allow?a.agent.allow.split(";"):[],a.agent.nat=a.agent.nat?a.agent.nat.split(","):[]})["catch"](function(a){c.show(a.message,"danger")})},a.patchItem=function(){return g.patch({id:e.id},{chatCapacity:a.agent.chatCapacity,mailCapacity:a.agent.mailCapacity,faxCapacity:a.agent.faxCapacity}).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.message,"danger")})},a.updateItem=function(){var b=angular.copy(a.agent);return delete b.password,delete b.md5secret,b.transport=b.transport.join(","),b.allow=b.allow.join(";"),b.nat=b.nat.join(","),g.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.agents.view",{url:"/view/:id",templateUrl:"app/staff/agent/view/view.html",controller:"AgentViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.staff.agents.view.account",{url:"/account",templateUrl:"app/staff/agent/view/view.account.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/scripts/jquery.sparkline.min.js","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js","assets/scripts/profile.js"]})}]}}).state("main.staff.agents.view.voice",{url:"/voice",templateUrl:"app/staff/agent/view/view.voice.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}}).state("main.staff.agents.view.chat",{url:"/chat",templateUrl:"app/staff/agent/view/view.chat.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}}).state("main.staff.agents.view.mail",{url:"/mail",templateUrl:"app/staff/agent/view/view.mail.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}}).state("main.staff.agents.view.fax",{url:"/fax",templateUrl:"app/staff/agent/view/view.fax.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}}).state("main.staff.agents.view.phonebar",{url:"/phonebar",templateUrl:"app/staff/agent/view/view.phonebar.html",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("AgentWizardCtrl",["$scope","$rootScope","Agent","Setting","xAlert","$location","$translate","$http","WizardHandler",function(a,b,c,d,e,f,g,h,i){a.forms={info:void 0,voice:void 0},a.item={role:"agent",allow:["alaw","ulaw","gsm"],transport:["udp"],context:"from-sip"},a.next=function(){i.wizard().next()},a.exitValidation=function(a){return a},a.getFirstFreeInternal=function(){return d.get({controller:"internal"}).$promise.then(function(b){a.item.internal=b.value})["catch"](function(a){e.show(a.data.message,"danger")})},a.createItem=function(){var b=angular.copy(a.item);return b.transport&&(b.transport=b.transport.join(",")),a.item.allow&&(b.allow=b.allow.join(";")),c.save(b).$promise.then(function(){f.path("/staff/agents/list")})["catch"](function(a){e.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.agents.wizard",{url:"/wizard",templateUrl:"app/staff/agent/wizard/wizard.html",controller:"AgentWizardCtrl",data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff",{url:"/staff",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TeamCreateCtrl",["$scope","$uibModalInstance","Team","xAlert",function(a,b,c,d){a.form={},a.item={},a.ok=function(){return c.save(a.item).$promise.then(function(){b.close(a.item)})["catch"](function(a){d.show(a.data.message,"danger")})},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("TeamListCtrl",["$scope","Team","gridOptions","$uibModal",function(a,b,c,d){a.initView=function(){var d={exporterCsvFilename:"teams.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"{{row.entity.defaultEntry ? 'blue-hoki disabled' : 'blue-hoki'}}",href:"/staff/teams/view/{{row.entity.id}}/settings",name:"profile"},{"class":"{{row.entity.defaultEntry ? 'red-sunglo disabled' : 'red-sunglo'}}",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.createItem=function(){d.open({animation:!0,templateUrl:"app/staff/team/list/create.modal.html",controller:"TeamCreateCtrl"}).result.then(function(){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.teams.list",{url:"/list",templateUrl:"app/staff/team/list/list.html",controller:"TeamListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Team",["$resource",function(a){return a("/api/teams/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.teams",{url:"/teams",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("TeamViewCtrl",["$scope","$http","$stateParams","$translate","Team","Agent","xAlert",function(a,b,c,d,e,f,g){var h=function(){return{select:function(b){return console.log("agents",b),e.save({id:a.team.id,controller:"agents"},{agents:b})},deselect:function(b){return e["delete"]({id:a.team.id,controller:"agents",agents:b})}}};a.initView=function(){return e.get({id:c.id}).$promise.then(function(b){a.team=b})["catch"](function(a){g.show(a.message,"danger")})},a.initAgents=function(){return f.get().$promise.then(function(b){return a.agents=b.rows,e.query({id:c.id,controller:"agents"}).$promise}).then(function(b){ComponentsDropdowns.bindTeam(_.map(b,"id"),_.map(a.agents,function(a){return{id:a.id,name:a.name,fullname:a.fullname,internal:a.internal}}),h)})["catch"](function(a){g.show(a.message,"danger")})},a.updateItem=function(){var b=angular.copy(a.team);return e.update({id:c.id},b).$promise.then(function(){g.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.teams.view",{url:"/view/:id",templateUrl:"app/staff/team/view/view.html",controller:"TeamViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.staff.teams.view.agents",{url:"/agents",templateUrl:"app/staff/team/view/view.agents.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/jquery-multi-select/css/multi-select.css","assets/plugins/jquery-multi-select/js/jquery.multi-select.js","assets/plugins/jquery-quicksearch/jquery.quicksearch.js","assets/scripts/components-dropdowns.js"]}])}]}}).state("main.staff.teams.view.settings",{url:"/settings",templateUrl:"app/staff/team/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("TelephoneListCtrl",["$scope","Telephone","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"telephones.csv",columnDefs:[{name:"fullname"},{name:"name"},{name:"accountcode"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/staff/telephones/view/{{row.entity.id}}/account",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.fullname, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.telephones.list",{url:"/list",templateUrl:"app/staff/telephone/list/list.html",controller:"TelephoneListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").factory("Telephone",["$resource",function(a){return a("/api/telephones/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.telephones",{url:"/telephones",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("TelephoneViewCtrl",["$scope","$http","$stateParams","$translate","$cookieStore","Auth","xAlert","Telephone",function(a,b,c,d,e,f,g,h){a.initView=function(){a.Auth=f,a.forms={},h.get({id:c.id}).$promise.then(function(b){delete b.password,a.item=b,a.item.transport=a.item.transport?a.item.transport.split(","):[],a.item.allow=a.item.allow?a.item.allow.split(";"):[]})["catch"](function(a){g.show(a.message,"danger")})},a.updateItem=function(){var b=angular.copy(a.item);b.transport=b.transport.join(","),b.allow=b.allow.join(";"),h.update(b).$promise.then(function(){g.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){g.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.telephones.view",{url:"/view/:id",templateUrl:"app/staff/telephone/view/view.html",controller:"TelephoneViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.staff.telephones.view.account",{url:"/account",templateUrl:"app/staff/telephone/view/view.account.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css","assets/scripts/jquery.sparkline.min.js","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js","assets/scripts/profile.js"]})}]}})}]),angular.module("xCallyShuttleApp").controller("TelephoneWizardCtrl",["$scope","$http","$location","WizardHandler","xAlert","$translate","Telephone",function(a,b,c,d,e,f,g){a.next=function(){d.wizard().next()},a.exitValidation=function(a){return a},a.initWizard=function(){return a.forms={},a.item={allow:["alaw","ulaw","gsm"],transport:["udp"],context:"from-sip"},g.get({id:"internal"}).$promise.then(function(b){a.item.internal=b.internal})["catch"](function(a){console.error(a)})},a.createItem=function(){var b=angular.copy(a.item);return b.transport&&(b.transport=b.transport.join(",")),a.item.allow&&(b.allow=b.allow.join(";")),g.save(b).$promise.then(function(){c.path("/staff/telephones/list")})["catch"](function(a){e.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.telephones.wizard",{url:"/wizard",templateUrl:"app/staff/telephone/wizard/wizard.html",controller:"TelephoneWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("UserListCtrl",["$scope","User","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"users.csv",columnDefs:[{name:"fullname"},{name:"name",displayName:"APPLICATION_USERNAME"},{name:"email"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/staff/users/view/{{row.entity.id}}/account",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.fullname, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.users.list",{url:"/list",templateUrl:"app/staff/user/list/list.html",controller:"UserListCtrl"})}]),angular.module("xCallyShuttleApp").factory("User",["$resource",function(a){return a("/api/users/:id/:controller",{id:"@id"},{changePassword:{method:"PUT",params:{controller:"password"}},update:{method:"PUT"},me:{method:"GET",params:{id:"me"}}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.users",{url:"/users",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("UserViewCtrl",["$scope","$stateParams","$cookieStore","$translate","FileUploader","User","Auth","xAlert",function(a,b,c,d,e,f,g,h){a.Auth=g,a.initView=function(){return f.get({id:b.id}).$promise.then(function(b){a.user=b,a.user.transport=a.user.transport?a.user.transport.split(","):[],a.user.allow=a.user.allow?a.user.allow.split(";"):[]})["catch"](function(a){h.show(a.message,"danger")})},a.updateItem=function(){var c=angular.copy(a.user);return delete c.password,delete c.md5secret,c.transport=c.transport.join(","),c.allow=c.allow.join(";"),f.update({id:b.id},c).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})},a.updatePassword=function(){var c={newPassword:a.user.newPwd};return g.isAdmin()?c.id=b.id:c.oldPassword=a.user.currentPwd,f.changePassword(c).$promise.then(function(){h.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){h.show(a.message,"danger")})};var i=a.uploader=new e({url:"api/users/"+b.id+"/avatar",queueLimit:1,withCredentials:!0,headers:{Authorization:"Bearer "+c.get("token")}});i.filters.push({name:"imageFilter",fn:function(a){var b="|"+a.type.slice(a.type.lastIndexOf("/")+1)+"|";return-1!=="|jpg|png|jpeg|".indexOf(b)}}),i.onSuccessItem=function(b,c){a.user.userpic=c.userpic,a.user.id===g.getCurrentUser().id&&(g.getCurrentUser().userpic=c.userpic),h.show(d.instant("MESSAGE_WELL_DONE"),"success")},i.onErrorItem=function(){h.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")},i.onCompleteAll=function(){i.clearQueue()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.users.view",{url:"/view/:id",templateUrl:"app/staff/user/view/view.html",controller:"UserViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.staff.users.view.account",{url:"/account",templateUrl:"app/staff/user/view/view.account.html",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css","assets/scripts/jquery.sparkline.min.js","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js","assets/scripts/profile.js"]})}]}})}]),angular.module("xCallyShuttleApp").controller("UserWizardCtrl",["$scope","$location","WizardHandler","xAlert","$translate","User",function(a,b,c,d,e,f){a.forms={info:void 0,voice:void 0},a.item={role:"user",host:"dynamic",context:"from-sip"},a.next=function(){c.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){return f.save(a.item).$promise.then(function(){b.path("/staff/users/list")})["catch"](function(a){d.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.staff.users.wizard",{url:"/wizard",templateUrl:"app/staff/user/wizard/wizard.html",controller:"UserWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("SugarcrmListCtrl",["$scope","SugarcrmAccount","gridOptions","xAlert","$translate","Modal",function(a,b,c,d,e,f){a.initView=function(){var d={exporterCsvFilename:"sugarcrm_account.csv",columnDefs:[{name:"name",displayName:"APPLICATION_NAME"},{name:"username"},{name:"remoteUri",displayName:"APPLICATION_REMOTE_ADDRESS"},{name:"action",width:250,buttons:[{"class":"blue-hoki",href:"/sugarcrm/view/{{row.entity.id}}/account",name:"profile"},{"class":"green-jungle",name:"check",displayName:"APPLICATION_CHECK_CONNECTION",onClick:"grid.appScope.checkAccount(row.entity.id)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.checkAccount=function(a){return b.get({id:a,controller:"check"}).$promise.then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(a){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.sugarcrm.list",{url:"/list",templateUrl:"app/sugarcrm/list/list.html",controller:"SugarcrmListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.sugarcrm",{url:"/sugarcrm",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").factory("SugarcrmAccount",["$resource",function(a){return a("/api/sugarcrm/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("SugarcrmConfiguration",["$resource",function(a){return a("/api/sugarcrm/configurations/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").factory("SugarcrmField",["$resource",function(a){return a("/api/sugarcrm/fields/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").controller("SugarcrmViewCtrl",["$scope","$http","$stateParams","$translate","$location","$filter","WizardHandler","socket","xAlert","Modal",function(a,b,c,d,e,f,g,h,i,j){a.$stateParams=c,a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:500,scrollInertia:0},a.initConfiguration=function(){a.formsConfiguration={},a.configuration={}},a.goNext=function(){g.wizard().next()},a.formValidation=function(a){return a},a.$on("$destroy",function(){h.unsyncUpdates("sugarcrm_configuration"),h.unsyncUpdates("sugarcrm_field")}),a.initView=function(){b.get("/api/sugarcrm/accounts/"+c.id).success(function(b){a.account=b}).error(function(a){i.show(a.message,"danger")})},a.updateItem=function(){b.put("/api/sugarcrm/accounts/"+c.id,a.account).success(function(){i.show(d.instant("MESSAGE_WELL_DONE")+".","success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getConfigurations=function(){b.get("/api/sugarcrm/configurations",{params:{AccountId:c.id}}).success(function(b){a.configurations=b,h.socket.on("sugarcrm_configuration:remove",function(b){_.remove(a.configurations,{id:b.id})})}).error(function(a){i.show(a.message,"danger")})},a.deleteConfiguration=j.confirm["delete"](function(a){b["delete"]("api/sugarcrm/configurations/"+a).success(function(){i.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})}),a.createConfiguration=function(){a.configuration.AccountId=c.id,b.post("api/sugarcrm/configurations",a.configuration).success(function(a){e.path("sugarcrm/view/"+c.id+"/configurations/settings/"+a.id)}).error(function(){i.show("Something went wrong!","danger")})},a.fieldType=["string","variable"],a.descFieldType=["string","key_value"],a.getFields=function(){b.get("/api/sugarcrm/accounts/"+c.id+"/fields").success(function(b){a.accountFields=_.sortByOrder(f("sugarcrm")(_.toArray(b)),"name","asc"),_.forEach(b,function(a){a.options=_.toArray(a.options)})}).error(function(a){i.show(a.message,"danger")})},a.getConfiguration=function(){b.get("/api/sugarcrm/configurations/"+c.configurationId).success(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,h.socket.on("sugarcrm_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})}).error(function(a){i.show(a.message,"danger")})},a.getVariables=function(){b.get("/api/variables").success(function(b){a.variables=b.rows}).error(function(a){i.show(a.message,"danger")})},a.removeItem=function(a){b["delete"]("api/sugarcrm/fields/"+a.id).success(function(){i.show(d.instant("MESSAGE_WELL_DONE"),"success")}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.addItemSubject=function(){var d={type:"string",content:""};b.post("/api/sugarcrm/configurations/"+c.configurationId+"/subject",d).success(function(b){a.subjectConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.addItemDescription=function(){var d={type:"string",content:""};b.post("/api/sugarcrm/configurations/"+c.configurationId+"/description",d).success(function(b){a.descriptionConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.addItemField=function(){var d={content:""};b.post("/api/sugarcrm/configurations/"+c.configurationId+"/field",d).success(function(b){a.fieldConfig.push(b)}).error(function(){i.show("Something went wrong!","danger")})},a.updateField=function(a){b.put("/api/sugarcrm/fields/"+a.id,a).success(function(){}).error(function(){i.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.changeType=function(b){"variable"===b.type?b.content="":"string"===b.type&&(b.VariableId=null),a.updateField(b)},a.changeDescType=function(b){"key_value"===b.type?(b.content="","string"===b.keyType?b.VariableId=null:"variable"===b.keyType&&(b.keyContent="")):"string"===b.type&&(b.VariableId=null,b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){b.content="",a.updateField(b)},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"name",b);return c?c.options.length>0?c.options:null:void 0}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.sugarcrm.view",{url:"/view/:id",templateUrl:"app/sugarcrm/view/view.html",controller:"SugarcrmViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.sugarcrm.view.account",{url:"/account",templateUrl:"app/sugarcrm/view/view.account.html"}).state("main.sugarcrm.view.configurations",{url:"/configurations",templateUrl:"app/sugarcrm/view/view.configurations.html"}).state("main.sugarcrm.view.configurations.settings",{url:"/settings/:configurationId",templateUrl:"app/sugarcrm/view/view.configurationSettings.html",controller:"SugarcrmViewCtrl"}).state("main.sugarcrm.view.configuration",{url:"/configuration",templateUrl:"app/sugarcrm/view/view.configuration.html"})}]),angular.module("xCallyShuttleApp").controller("SugarcrmkWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler",function(a,b,c,d,e,f){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={}},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){b.post("api/sugarcrm/accounts",a.item).success(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/sugarcrm/list")}).error(function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.sugarcrm.wizard",{url:"/wizard",templateUrl:"app/sugarcrm/wizard/wizard.html",controller:"SugarcrmkWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("CannedAnswer",["$resource",function(a){return a("/api/answers/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.answers",{url:"/answers",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AnswerListCtrl",["$scope","$uibModal","CannedAnswer","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"answers.csv",columnDefs:[{name:"key",displayName:"APPLICATION_NAME"},{name:"value"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/answers/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.key, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){b.open({animation:!0,templateUrl:"app/tools/answer/list/list.create.modal.html",controller:"AnswerListCreateCtrl"}).result.then(function(b){a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("AnswerListCreateCtrl",["$scope","$translate","$uibModalInstance","CannedAnswer","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.answers.list",{url:"/list",templateUrl:"app/tools/answer/list/list.html",controller:"AnswerListCtrl"})}]),angular.module("xCallyShuttleApp").controller("AnswerViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location","CannedAnswer",function(a,b,c,d,e,f,g){a.getAnswer=function(){return g.get({id:e.id}).$promise.then(function(b){a.answer=b})["catch"](function(a){c.show(a.data.message,"danger")})},a.updateAnswer=function(){var b=angular.copy(a.answer);return g.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.answers.view",{url:"/view/:id",templateUrl:"app/tools/answer/view/view.html",controller:"AnswerViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before", -files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.answers.view.settings",{url:"/settings",templateUrl:"app/tools/answer/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("Automation",["$resource",function(a){return a("/api/automations/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.automations",{url:"/automations",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("AutomationListCtrl",["$scope","$http","$translate","xAlert","Automation","gridOptions",function(a,b,c,d,e,f){a.onText="On",a.offText="Off",a.isActive=!0,a.size="mini",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initView=function(){var b={exporterCsvFilename:"Automations.csv",columnDefs:[{name:"name"},{name:"description"},{name:"channel"},{name:"status",cellTemplate:'
',width:100,enableFiltering:!1},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/automations/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=f.gridOptions(e,b,a)},a.updateItem=function(a){return e.update({id:a.id},a).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.error(a),d.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.automations.list",{url:"/list",templateUrl:"app/tools/automation/list/list.html",controller:"AutomationListCtrl"})}]),angular.module("xCallyShuttleApp").controller("AutomationViewCtrl",["$scope","$stateParams","$http","$translate","xAlert","automations","Automation","$location",function(a,b,c,d,e,f,g,h){a.$automations=f,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.forms={general:{}},a.addCondition=function(b){a.automation[b].push({field:"",operator:"",value:""})},a.removeCondition=function(b,c){a.automation[b].splice(c,1)},a.addAction=function(){a.automation.Actions.push({action:"",data1:"",data2:"",data3:"",data4:"",data5:""})},a.resetActionData=function(a){a.data1="",a.data2="",a.data3="",a.data4="",a.data5=""},a.removeAction=function(b){a.automation.Actions.splice(b,1)},a.initView=function(){return g.get({id:b.id}).$promise.then(function(b){a.automation=b})["catch"](function(a){e.show(a.message,"danger"),h.path("/tools/automations/list")})},a.updateAutomation=function(){return g.update({id:b.id},a.automation).$promise.then(function(){e.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.error(a),e.show(a.message,"danger")})},a.exitValidation=function(b){return console.log(b&&(a.automation.All.length||a.automation.Any.length)&&a.automation.Actions.length),b&&(a.automation.All.length||a.automation.Any.length)&&a.automation.Actions.length?!0:!1}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.automations.view",{url:"/view/:id",templateUrl:"app/tools/automation/view/view.html",controller:"AutomationViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]})}]}}).state("main.tools.automations.view.settings",{url:"/settings",templateUrl:"app/tools/automation/view/view.settings.html"}).state("main.tools.automations.view.routes",{url:"/routes",templateUrl:"app/tools/automation/view/view.routes.html"}).state("main.tools.automations.view.application",{url:"/application",templateUrl:"app/tools/automation/view/view.application.html"})}]),angular.module("xCallyShuttleApp").controller("AutomationWizardCtrl",["$scope","$http","$location","xAlert","automations","WizardHandler","Automation",function(a,b,c,d,e,f,g){a.$automations=e,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.tempData={voice:{},mail:{},chat:{},fax:{}},a.item={All:[],Any:[],Actions:[]},a.forms={general:void 0,settings:void 0},a.addCondition=function(b){a.item[b].push({field:"",operator:"",value:""})},a.removeCondition=function(b,c){a.item[b].splice(c,1)},a.addAction=function(){a.item.Actions.push({action:"",data1:"",data2:"",data3:"",data4:"",data5:""})},a.resetActionData=function(a){a.data1="",a.data2="",a.data3="",a.data4="",a.data5=""},a.removeAction=function(b){a.item.Actions.splice(b,1)},a.$watch("item.channel",function(b,c){c&&(a.tempData[c].All=_.clone(a.item.All,!0),a.tempData[c].Any=_.clone(a.item.Any,!0),a.tempData[c].Actions=_.clone(a.item.Actions,!0)),a.item.All=a.tempData[b].All?a.tempData[b].All:[],a.item.Any=a.tempData[b].Any?a.tempData[b].Any:[],a.item.Actions=a.tempData[b].Actions?a.tempData[b].Actions:[]},!0),a.item.channel="voice",a.createItem=function(){return g.save(a.item).$promise.then(function(){c.path("/tools/automations/list")})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},a.next=function(){f.wizard().next()},a.previous=function(){f.wizard().previous()},a.exitValidation=function(a){return a},a.exitSettingsValidation=function(b){return b&&(a.item.All.length||a.item.Any.length)&&a.item.Actions.length?!0:!1}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.automations.wizard",{url:"/wizard",templateUrl:"app/tools/automation/wizard/wizard.html",controller:"AutomationWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("Interval",["$resource",function(a){return a("/api/intervals/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.intervals",{url:"/intervals",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("IntervalListCtrl",["$scope","$uibModal","Interval","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"intervals.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/intervals/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/tools/interval/list/list.create.modal.html",controller:"IntervalListCreateCtrl"});c.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("IntervalListCreateCtrl",["$scope","$translate","$uibModalInstance","Interval","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(b.instant(a.data.message),"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.intervals.list",{url:"/list",templateUrl:"app/tools/interval/list/list.html",controller:"IntervalListCtrl"})}]),angular.module("xCallyShuttleApp").controller("IntervalViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","socket","$location","WizardHandler","Modal","interval",function(a,b,c,d,e,f,g,h,i,j){function k(b){console.log(b);var c,d,e,f;c=b.t_from&&b.t_to&&!b.alwaysTime?moment(b.t_from).format("HH:mm")+"-"+moment(b.t_to).format("HH:mm"):"*",b.wd_from&&"always"!==b.wd_from?(d=b.wd_from,b.wd_to&&"always"!==b.wd_to&&(d+="-"+b.wd_to)):d="*",b.md_from&&"always"!==b.md_from?(e=b.md_from,b.md_to&&"always"!==b.md_to&&(e+="-"+b.md_to)):e="*",b.m_from&&"always"!==b.m_from?(f=b.m_from,b.m_to&&"always"!==b.m_to&&(f+="-"+b.m_to)):f="*",void 0!==a.selectedSubInterval?a.interval.SubIntervals[a.selectedSubInterval].interval=c+","+d+","+e+","+f:a.subinterval.interval=c+","+d+","+e+","+f}a.$translate=d,a.$interval=j.interval,a.selectedSubInterval=void 0,a.gridOptions={columnDefs:[{name:"name",displayName:"APPLICATION_NAME",headerCellFilter:"translate"},{name:"interval",displayName:"APPLICATION_INTERVAL",headerCellFilter:"translate"},{name:"action",displayName:"APPLICATION_ACTION",headerCellFilter:"translate",width:125,cellTemplate:'{{\'APPLICATION_SETTINGS\' | translate}}{{\'APPLICATION_DELETE\' | translate}}'}]},a.forms={subinterval:void 0,general:void 0},a.initSubInterval=function(b){b&&(a.selectedSubInterval=void 0),a.subinterval={},a.splittedInterval={t_from:moment(new Date),t_to:moment(new Date),wd_from:"always",wd_to:"always",md_from:"always",md_to:"always",m_from:"always",m_to:"always",alwaysTime:!0}},a.next=function(){h.wizard().next()},a.previous=function(){h.wizard().previous()},a.exitValidation=function(a){return a},a.deselectAndRedirect=function(b){a.selectedSubInterval=void 0,g.path(b)},a.getInterval=function(){b.get("/api/intervals/"+e.id).success(function(b){a.interval=b,a.gridOptions.data=b.SubIntervals}).error(function(a){console.error(a),g.path("/tools/intervals/list")})},a.openSubInterval=function(b){a.selectedSubInterval=b,g.path("/tools/intervals/view/"+e.id+"/subintervals/settings")},a.updateInterval=function(f){a.selectedSubInterval=void 0,b.put("/api/intervals/"+e.id,a.interval).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success"),f&&g.path("/tools/intervals/view/"+e.id+"/"+f)}).error(function(a){c.show(d.instant(a.message),"danger")})},a.getSubInterval=function(){void 0===a.selectedSubInterval&&g.path("/tools/intervals/list"),a.splittedInterval={t_from:moment(new Date),t_to:moment(new Date)};var b,c=a.interval.SubIntervals[a.selectedSubInterval]?a.interval.SubIntervals[a.selectedSubInterval].interval.split(","):["*","*","*","*"];c.forEach(function(c,d){switch(d){case 0:"*"!==c?(b=c.split("-"),a.splittedInterval.t_from=moment(b[0],"HH:mm"),a.splittedInterval.t_to=moment(b[1],"HH:mm"),a.splittedInterval.alwaysTime=!1):(a.splittedInterval.t_from=moment(new Date),a.splittedInterval.t_to=moment(new Date),a.splittedInterval.alwaysTime=!0);break;case 1:"*"!==c?(b=c.split("-"),a.splittedInterval.wd_from=b[0],a.splittedInterval.wd_to=b[1]?b[1]:"always"):(a.splittedInterval.wd_from="always",a.splittedInterval.wd_to="always");break;case 2:"*"!==c?(b=c.split("-"),a.splittedInterval.md_from=b[0],a.splittedInterval.md_to=b[1]?b[1]:"always"):(a.splittedInterval.md_from="always",a.splittedInterval.md_to="always");break;case 3:"*"!==c?(b=c.split("-"),a.splittedInterval.m_from=b[0],a.splittedInterval.m_to=b[1]?b[1]:"always"):(a.splittedInterval.m_from="always",a.splittedInterval.m_to="always")}})},a.$watch("splittedInterval",function(a){a&&k(a)},!0),a.addSubInterval=function(){a.interval.SubIntervals.push(a.subinterval),a.updateInterval("subintervals")},a.deleteSubInterval=i.confirm["delete"](function(b){a.interval.SubIntervals.splice(b,1),a.updateInterval()})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.intervals.view",{url:"/view/:id",templateUrl:"app/tools/interval/view/view.html",controller:"IntervalViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.intervals.view.settings",{url:"/settings",templateUrl:"app/tools/interval/view/view.settings.html"}).state("main.tools.intervals.view.subintervals",{url:"/subintervals",templateUrl:"app/tools/interval/view/view.subintervals.html"}).state("main.tools.intervals.view.subinterval",{url:"/subinterval",templateUrl:"app/tools/interval/view/view.subinterval.html"}).state("main.tools.intervals.view.subintervals.settings",{url:"/settings",templateUrl:"app/tools/interval/view/view.subintervalSettings.html"})}]),angular.module("xCallyShuttleApp").controller("PauseListCtrl",["$scope","$log","$uibModal","$translate","Pause","gridOptions",function(a,b,c,d,e,f){a.initView=function(){var b={exporterCsvFilename:"pauses.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/pauses/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=f.gridOptions(e,b,a)},a.createItem=function(){var b=c.open({animation:!0,templateUrl:"app/tools/pause/list/list.create.modal.html",controller:"PauseListCreateCtrl"});b.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("PauseListCreateCtrl",["$scope","$translate","$uibModalInstance","Pause","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.pauses.list",{url:"/list",templateUrl:"app/tools/pause/list/list.html",controller:"PauseListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Pause",["$resource",function(a){return a("/api/pauses/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.pauses",{url:"/pauses",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("PauseViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location","Pause",function(a,b,c,d,e,f,g){a.getPause=function(){return g.get({id:e.id}).$promise.then(function(b){a.pause=b})["catch"](function(a){c.show(a.data.message,"danger")})},a.updatePause=function(){var b=angular.copy(a.pause);return g.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.pauses.view",{url:"/view/:id",templateUrl:"app/tools/pause/view/view.html",controller:"PauseViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.pauses.view.settings",{url:"/settings",templateUrl:"app/tools/pause/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("SoundListCtrl",["$scope","$http","socket","Modal","$q","FileUploader","$translate","xAlert","$cookieStore","$sce","Sound",function(a,b,c,d,e,f,g,h,i,j,k){a.Sound=k,a.isCollapsed=!0,a.downloadButtonContent='',a.downloadButtonClass="btn btn-xs blue-hoki",a["delete"]=d.confirm["delete"](function(a){b["delete"]("/api/sounds/"+a).success(function(a){}).error(function(a){console.log(a)})}),a.updateAudio=function(a,c){var d=e.defer();return b.put("/api/sounds/"+a,c).success(function(a){d.resolve()}).error(function(a){console.log(a.message),d.reject(a.message)}),d.promise},a.$on("$destroy",function(){c.unsyncUpdates("sound")}),a.initList=function(){b.get("/api/sounds").success(function(b){a.sounds=b.rows,b.rows.length||(a.isCollapsed=!1),c.syncUpdates("sound",a.sounds,function(){a.sounds.length||(a.isCollapsed=!1)})}).error(function(a){})};var l=a.uploader=new f({url:"/api/sounds",withCredentials:!0,headers:{Authorization:"Bearer "+i.get("token")}});l.filters.push({name:"customFilter",fn:function(a,b){return this.queue.length<10}}),l.onWhenAddingFileFailed=function(a,b,c){console.info("onWhenAddingFileFailed",a,b,c)},l.onAfterAddingFile=function(a){console.info("onAfterAddingFile",a)},l.onAfterAddingAll=function(a){console.info("onAfterAddingAll",a)},l.onBeforeUploadItem=function(a){console.info("onBeforeUploadItem",a)},l.onProgressItem=function(a,b){console.info("onProgressItem",a,b),a.isUploading=!0},l.onProgressAll=function(a){console.info("onProgressAll",a)},l.onSuccessItem=function(a,b,c,d){console.info("onSuccessItem",a,b,c,d),a.isUploading=!1},l.onErrorItem=function(a,b,c,d){console.info("onErrorItem",a,b,c,d),a.responseMessage=b,a.isUploading=!1},l.onCancelItem=function(a,b,c,d){console.info("onCancelItem",a,b,c,d),a.isUploading=!1},l.onCompleteItem=function(a,b,c,d){console.info("onCompleteItem",a,b,c,d),a.isUploading=!1},l.onCompleteAll=function(){console.info("onCompleteAll")},console.info("uploader",l)}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.sounds.list",{url:"/list",templateUrl:"app/tools/sound/list/list.html",controller:"SoundListCtrl",authenticate:!0,resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/plugins/bootstrap-fileinput/bootstrap-fileinput.js"]})}]}})}]),angular.module("xCallyShuttleApp").factory("Sound",["$resource",function(a){return a("/api/sounds/:id/:controller",{name:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.sounds",{url:"/sounds",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TagListCtrl",["$scope","$uibModal","Tag","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"tag.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/tags/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/tools/tag/list/list.create.modal.html",controller:"TagListCreateCtrl"});c.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("TagListCreateCtrl",["$scope","$translate","$uibModalInstance","Tag","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.tags.list",{url:"/list",templateUrl:"app/tools/tag/list/list.html",controller:"TagListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Tag",["$resource",function(a){return a("/api/tags/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.tags",{url:"/tags",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TagViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location","Tag",function(a,b,c,d,e,f,g){a.getTag=function(){return g.get({id:e.id}).$promise.then(function(b){a.tag=b})["catch"](function(a){c.show(a.data.message,"danger")})},a.updateTag=function(){var b=angular.copy(a.tag);return g.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){c.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.tags.view",{url:"/view/:id",templateUrl:"app/tools/tag/view/view.html",controller:"TagViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.tags.view.settings",{url:"/settings",templateUrl:"app/tools/tag/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("TemplateListCtrl",["$scope","Template","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"templates.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/tools/templates/view/{{row.entity.id}}/settings",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.templates.list",{url:"/list",templateUrl:"app/tools/template/list/list.html",controller:"TemplateListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Template",["$resource",function(a){return a("/api/mail/templates/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.templates",{url:"/templates",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TemplateViewCtrl",["$scope","$http","$translate","$stateParams","xAlert","Template",function(a,b,c,d,e,f){a.initItem=function(){a.form={},a.item={},a.groups=[{title:"Voice",variables:[]},{title:"Chat",variables:["username","email","text","chatWebsite"]},{title:"Mail",variables:[]},{title:"Fax",variables:[]}],a.item=f.get({id:d.id})},a.updateItem=function(){f.update(a.item).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){e.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.templates.view",{url:"/view/:id",templateUrl:"app/tools/template/view/view.html",controller:"TemplateViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.templates.view.settings",{url:"/settings",templateUrl:"app/tools/template/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("TemplateWizardCtrl",["$scope","$location","$http","WizardHandler","xAlert","Template",function(a,b,c,d,e,f){a.initWizard=function(){a.item={},a.form={},a.groups=[{title:"Voice",variables:[]},{title:"Chat",variables:["username","email","text","chatWebsite"]},{title:"Mail",variables:[]},{title:"Fax",variables:[]}]},a.next=function(){d.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){return f.save({name:a.item.name,description:a.item.description,subject:a.item.subject||null,html:a.item.html||null,text:a.item.text||null}).$promise.then(function(){b.path("/tools/templates/list")})["catch"](function(a){e.show(data.err.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.templates.wizard",{url:"/wizard",templateUrl:"app/tools/template/wizard/wizard.html",controller:"TemplateWizardCtrl"})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools",{url:"/tools",template:"
","abstract":!0,data:{permissions:{only:["admin"],redirectTo:"main.dashboard.voice"}}})}]),angular.module("xCallyShuttleApp").controller("TriggerListCtrl",["$scope","$http","$translate","Modal","xAlert","Trigger","gridOptions",function(a,b,c,d,e,f,g){a.onText="On",a.offText="Off",a.isActive=!0,a.size="mini",a.animate=!0,a.radioOff=!0,a.handleWidth="auto",a.labelWidth="auto",a.inverse=!0,a.offColor="danger",a.onColor="success",a.initView=function(){var b={exporterCsvFilename:"Triggers.csv",columnDefs:[{name:"name"},{name:"description"},{name:"channel"},{name:"status",cellTemplate:'
',width:100,enableFiltering:!1},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/triggers/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=g.gridOptions(f,b,a)},a.updateItem=function(a){return f.update({id:a.id},a).$promise.then(function(){e.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.error(a),e.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.triggers.list",{url:"/list",templateUrl:"app/tools/trigger/list/list.html",controller:"TriggerListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Trigger",["$resource",function(a){return a("/api/triggers/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.triggers",{url:"/triggers",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TriggerViewCtrl",["$scope","$stateParams","$translate","xAlert","triggers","Trigger","$location",function(a,b,c,d,e,f,g){a.$triggers=e,a.recordSwitch={onText:"On",offText:"Off",isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.forms={general:{}},a.addCondition=function(b){a.trigger[b].push({field:"",operator:"",value:""})},a.removeCondition=function(b,c){a.trigger[b].splice(c,1)},a.addAction=function(){a.trigger.Actions.push({action:"",data1:"",data2:"",data3:"",data4:"",data5:""})},a.resetActionData=function(a){a.data1="",a.data2="",a.data3="",a.data4="",a.data5=""},a.removeAction=function(b){a.trigger.Actions.splice(b,1)},a.initView=function(){return f.get({id:b.id}).$promise.then(function(b){a.trigger=b})["catch"](function(a){d.show(a.message,"danger"),g.path("/tools/triggers/list")})},a.updateTrigger=function(){return f.update({id:b.id},a.trigger).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},a.exitValidation=function(b){return console.log(b&&(a.trigger.All.length||a.trigger.Any.length)&&a.trigger.Actions.length),b&&(a.trigger.All.length||a.trigger.Any.length)&&a.trigger.Actions.length?!0:!1}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.triggers.view",{url:"/view/:id",templateUrl:"app/tools/trigger/view/view.html",controller:"TriggerViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load({insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]})}]}}).state("main.tools.triggers.view.settings",{url:"/settings",templateUrl:"app/tools/trigger/view/view.settings.html"}).state("main.tools.triggers.view.routes",{url:"/routes",templateUrl:"app/tools/trigger/view/view.routes.html"}).state("main.tools.triggers.view.application",{url:"/application",templateUrl:"app/tools/trigger/view/view.application.html"})}]),angular.module("xCallyShuttleApp").controller("TriggerWizardCtrl",["$scope","$http","$location","xAlert","triggers","WizardHandler","Trigger",function(a,b,c,d,e,f,g){a.$triggers=e,a.tempData={voice:{},mail:{},chat:{},fax:{}},a.item={All:[],Any:[],Actions:[]},a.forms={general:void 0,settings:void 0},a.addCondition=function(b){a.item[b].push({field:"",operator:"",value:""})},a.removeCondition=function(b,c){a.item[b].splice(c,1)},a.addAction=function(){a.item.Actions.push({action:"",data1:"",data2:"",data3:"",data4:"",data5:""})},a.resetActionData=function(a){a.data1="",a.data2="",a.data3="",a.data4="",a.data5=""},a.removeAction=function(b){a.item.Actions.splice(b,1)},a.$watch("item.channel",function(b,c){c&&(a.tempData[c].All=_.clone(a.item.All,!0),a.tempData[c].Any=_.clone(a.item.Any,!0),a.tempData[c].Actions=_.clone(a.item.Actions,!0)),a.item.All=a.tempData[b].All?a.tempData[b].All:[],a.item.Any=a.tempData[b].Any?a.tempData[b].Any:[],a.item.Actions=a.tempData[b].Actions?a.tempData[b].Actions:[]},!0),a.item.channel="voice",a.createItem=function(){return g.save(a.item).$promise.then(function(){c.path("/tools/triggers/list")})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},a.next=function(){f.wizard().next()},a.previous=function(){f.wizard().previous()},a.exitValidation=function(a){return a},a.exitSettingsValidation=function(b){return b&&(a.item.All.length||a.item.Any.length)&&a.item.Actions.length?!0:!1}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.triggers.wizard",{url:"/wizard",templateUrl:"app/tools/trigger/wizard/wizard.html",controller:"TriggerWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("TrunkListCtrl",["$scope","Trunk","gridOptions",function(a,b,c){a.initView=function(){var d={exporterCsvFilename:"Trunks.csv",columnDefs:[{name:"name"},{name:"host"},{name:"context"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/trunks/view/{{row.entity.name}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.name)"}]}]};a.gridOptions=c.gridOptions(b,d,a)}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.trunks.list",{url:"/list",templateUrl:"app/tools/trunk/list/list.html",controller:"TrunkListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Trunk",["$resource",function(a){return a("/api/trunks/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.trunks",{url:"/trunks",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("TrunkViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","socket","$location","Trunk","VoiceContext",function(a,b,c,d,e,f,g,h,i){a.initView=function(){return h.get({id:e.id}).$promise.then(function(b){b.nat=b.nat?b.nat.split(","):[],b.allow=b.allow?b.allow.split(";"):[],b.insecure=b.insecure?b.insecure.split(","):[],b.transport=b.transport?b.transport.split(","):[],a.trunk=b})["catch"](function(a){ -console.error(a),g.path("/tools/trunks/list")})},a.updateTrunk=function(){""===a.trunk.password&&delete a.trunk.password;var b=angular.copy(a.trunk);return b.nat=b.nat.join(","),b.allow=b.allow.join(";"),b.insecure=b.insecure.join(","),b.transport=b.transport.join(","),h.update({id:e.id},b).$promise.then(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(a){c.show(a.data.message,"danger")})},a.getContexts=function(){return i.get().$promise.then(function(b){a.voiceContexts=b.rows})["catch"](function(a){c.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.trunks.view",{url:"/view/:id",templateUrl:"app/tools/trunk/view/view.html",controller:"TrunkViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.trunks.view.settings",{url:"/settings",templateUrl:"app/tools/trunk/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("TrunkWizardCtrl",["$scope","$http","WizardHandler","$location","xAlert","socket","$translate",function(a,b,c,d,e,f,g){a.initWizard=function(){a.forms={},a.item={context:"from-voip-provider"}},a.next=function(d){d?b.post("/api/trunks/validate/",a.item).success(function(a){console.log(a),a.length?e.show(g.instant("MESSAGE_EXIST_TRUNK"),"danger"):c.wizard().next()}).error(function(a){e.show(g.instant(a.message),"danger")}):c.wizard().next()},a.previous=function(){c.wizard().previous()},a.exitValidation=function(a){return a},a.createItem=function(){b.post("/api/trunks/",a.item).success(function(){d.path("/tools/trunks/list")}).error(function(a){e.show(a.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.trunks.wizard",{url:"/wizard",templateUrl:"app/tools/trunk/wizard/wizard.html",controller:"TrunkWizardCtrl"})}]),angular.module("xCallyShuttleApp").controller("VariableListCtrl",["$scope","$uibModal","Variable","gridOptions",function(a,b,c,d){a.initView=function(){var b={exporterCsvFilename:"variables.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:160,buttons:[{"class":"blue-hoki",href:"/tools/variables/view/{{row.entity.id}}/settings",name:"settings"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(c,b,a)},a.createItem=function(){var c=b.open({animation:!0,templateUrl:"app/tools/variable/list/list.create.modal.html",controller:"VariableListCreateCtrl"});c.result.then(function(b){console.log(b),a.gridOptions.getPage()})}}]),angular.module("xCallyShuttleApp").controller("VariableListCreateCtrl",["$scope","$translate","$uibModalInstance","Variable","xAlert",function(a,b,c,d,e){a.form={},a.item={},a.save=function(){return d.save(a.item).$promise.then(function(a){e.show(b.instant("MESSAGE_WELL_DONE"),"success"),c.close(a)})["catch"](function(a){e.show(a.data.message,"danger")})},a.cancel=function(){c.dismiss()}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.variables.list",{url:"/list",templateUrl:"app/tools/variable/list/list.html",controller:"VariableListCtrl"})}]),angular.module("xCallyShuttleApp").factory("Variable",["$resource",function(a){return a("/api/variables/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.variables",{url:"/variables",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("VariableViewCtrl",["$scope","$translate","$stateParams","xAlert","Variable",function(a,b,c,d,e){a.getVariable=function(){return e.get({id:c.id}).$promise.then(function(b){a.variable=b})["catch"](function(a){d.show(a.data.message,"danger")})},a.updateVariable=function(){return e.update({id:c.id},a.variable).$promise.then(function(){d.show(b.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){d.show(a.data.message,"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.variables.view",{url:"/view/:id",templateUrl:"app/tools/variable/view/view.html",controller:"VariableViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.variables.view.settings",{url:"/settings",templateUrl:"app/tools/variable/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").controller("YourdashboardListCloneModalCtrl",["$scope","$uibModalInstance",function(a,b){a.forms={dashboard:void 0},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("YourdashboardListCreateModalCtrl",["$scope","$uibModalInstance",function(a,b){a.forms={dashboard:void 0},a.item={},a.ok=function(){a.item.model=JSON.stringify({title:a.item.name}),b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]),angular.module("xCallyShuttleApp").controller("YourdashboardListCtrl",["$scope","$http","$translate","xAlert","Modal","$uibModal","$log","YourDashboard","gridOptions",function(a,b,c,d,e,f,g,h,i){a.initView=function(){var b={exporterCsvFilename:"voice_contexts.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:220,buttons:[{"class":"green",href:"/tools/yourdashboards/show/{{row.entity.id}}",name:"view"},{"class":"blue-hoki",href:"/tools/yourdashboards/view/{{row.entity.id}}/settings",name:"settings"},{"class":"{{row.entity.defaultEntry ? 'red-sunglo disabled' : 'red-sunglo'}}",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"},{"class":"purple",name:"clone",onClick:"grid.appScope.clone(row.entity.id)"}]}]};a.gridOptions=i.gridOptions(h,b,a)},a.create=function(){var b=f.open({animation:!0,templateUrl:"app/tools/yourdashboard/list/create.modal.html",controller:"YourdashboardListCreateModalCtrl"});b.result.then(function(b){return h.save(b).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),a.gridOptions.getPage()})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},function(){g.info("Modal dismissed at: "+new Date)})},a.clone=function(b){var e=f.open({animation:!0,templateUrl:"app/tools/yourdashboard/list/clone.modal.html",controller:"YourdashboardListCloneModalCtrl"});e.result.then(function(e){return h.save({id:b,controller:"clone"},e).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE"),"success"),a.gridOptions.getPage()})["catch"](function(a){console.error(a),d.show(a.message,"danger")})},function(){g.info("Modal dismissed at: "+new Date)})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.yourdashboards.list",{url:"/list",templateUrl:"app/tools/yourdashboard/list/list.html",controller:"YourdashboardListCtrl"})}]),angular.module("xCallyShuttleApp").controller("YourdashboardShowCtrl",["$scope","localStorageService","$http","xAlert","$translate","Auth","$stateParams","$location",function(a,b,c,d,e,f,g,h){a.Auth=f,a.getDashboard=function(){c.get("/api/dashboards/"+g.id).success(function(b){var c={name:"dashboard",structure:"4-8",enableconfirmdelete:!0,maximizable:!0,collapsible:!0};b.model=JSON.parse(b.model||'{"title":"Dashboard"}'),b.editable=f.isAdmin()&&b.editable?!0:!1,a.dashboard=_.merge(c,b)}).error(function(a){h.path("/tools/yourdashboards/list")})};var i=function(b,f,h){var i=angular.copy(a.dashboard);i.name=a.dashboard.model.title,i.model=JSON.stringify(i.model),c.put("/api/dashboards/"+g.id,i).success(function(){d.show(e.instant("MESSAGE_DASHBOARD_SAVED")+"!","success")}).error(function(b){d.show(b.message,"danger"),i.model=JSON.parse(i.model),i.name="dashboard",a.dashboard=i})};a.$on("adfDashboardChanged",i),a.$on("destroy",function(){console.log("main dashboard")})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.yourdashboards.show",{url:"/show/:id",templateUrl:"app/tools/yourdashboard/show/show.html",controller:"YourdashboardShowCtrl"})}]),angular.module("xCallyShuttleApp").controller("YourdashboardViewCtrl",["$scope","$http","xAlert","$translate","$stateParams","$location",function(a,b,c,d,e,f){a.radioSwitch={isActive:!0,size:"small",animate:!0,radioOff:!0,handleWidth:"auto",labelWidth:"auto",inverse:!0,offColor:"danger",onColor:"success"},a.getDashboard=function(){b.get("/api/dashboards/"+e.id).success(function(b){delete b.model,a.dashboard=b}).error(function(a){f.path("/tools/yourdashboards/list")})},a.updateDashboard=function(){var f=angular.copy(a.dashboard);b.put("/api/dashboards/"+e.id,f).success(function(){c.show(d.instant("MESSAGE_WELL_DONE")+"!","success")}).error(function(b){c.show(d.instant(b.message),"danger"),a.dashboard=f})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.yourdashboards.view",{url:"/view/:id",templateUrl:"app/tools/yourdashboard/view/view.html",controller:"YourdashboardViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/plugins/bootstrap-fileinput/bootstrap-fileinput.css","assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.tools.yourdashboards.view.settings",{url:"/settings",templateUrl:"app/tools/yourdashboard/view/view.settings.html"})}]),angular.module("xCallyShuttleApp").factory("YourDashboard",["$resource",function(a){return a("/api/dashboards/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.tools.yourdashboards",{url:"/yourdashboards",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ZendeskListCtrl",["$scope","ZendeskAccount","gridOptions","xAlert","$translate",function(a,b,c,d,e){a.initView=function(){var d={exporterCsvFilename:"zendesk_account.csv",columnDefs:[{name:"name",displayName:"APPLICATION_NAME"},{name:"username"},{name:"remoteUri",displayName:"APPLICATION_REMOTE_ADDRESS"},{name:"action",width:250,buttons:[{"class":"blue-hoki",href:"/zendesk/view/{{row.entity.id}}/account",name:"profile"},{"class":"green-jungle",name:"check",displayName:"APPLICATION_CHECK_CONNECTION",onClick:"grid.appScope.checkAccount(row.entity.id)"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=c.gridOptions(b,d,a)},a.checkAccount=function(a){return b.check({id:a}).$promise.then(function(){d.show(e.instant("MESSAGE_ACCOUNT_VERIFIED"),"success")})["catch"](function(){d.show(e.instant("MESSAGE_ACCOUNT_INVALID"),"danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.list",{url:"/list",templateUrl:"app/zendesk/list/list.html",controller:"ZendeskListCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{name:"smart-table",insertBefore:"#ng_load_plugins_before",files:["assets/css/smart_table.css"]}])}]}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.view.configurations",{url:"/configurations",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").controller("ZendeskViewConfigurationListCtrl",["$scope","$stateParams","$translate","gridOptions","ZendeskConfiguration","$uibModal","xAlert",function(a,b,c,d,e,f,g){a.initView=function(){var c={exporterCsvFilename:"zendesk_configurations.csv",columnDefs:[{name:"name"},{name:"description"},{name:"action",width:125,buttons:[{"class":"blue-hoki",href:"/zendesk/view/{{row.entity.AccountId}}/configurations/view/{{row.entity.id}}",name:"profile"},{"class":"red-sunglo",name:"delete",onClick:"grid.appScope.deleteItem(row.entity.name, row.entity.id)"}]}]};a.gridOptions=d.gridOptions(e,c,a,{accountId:b.id})},a.createItem=function(){var c=f.open({animation:!0,templateUrl:"app/zendesk/view/configuration/list/create.modal.html",controller:["$scope","$uibModalInstance",function(a,b){a.form={},a.item={},a.ok=function(){b.close(a.item)},a.cancel=function(){b.dismiss("cancel")}}]});c.result.then(function(c){return e.save({accountId:b.id},c).$promise.then(function(){a.gridOptions.getPage()})["catch"](function(a){g.show(a.data.message,"danger")})})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.view.configurations.list",{url:"/list",templateUrl:"app/zendesk/view/configuration/list/list.html",controller:"ZendeskViewConfigurationListCtrl"})}]),angular.module("xCallyShuttleApp").controller("ZendeskViewConfigurationViewCtrl",["$scope","$stateParams","$filter","$translate","socket","ZendeskConfiguration","xAlert","variable","Variable","ZendeskAccount","Tag","ZendeskField",function(a,b,c,d,e,f,g,h,i,j,k,l){a.$on("$destroy",function(){e.unsyncUpdates("zendesk_field")}),a.config={autoHideScrollbar:!1,theme:"dark",advanced:{updateOnContentResize:!0},setHeight:300,scrollInertia:0},a.fieldType=[{type:"string",title:"String"},{type:"variable",title:"Variable"},{type:"customVariable",title:"Custom Variable"}],a.descFieldType=[{type:"string",title:"String"},{type:"keyValue",title:"Key Value"}],a.initView=function(){a.configurationName="",a.subjectConfig=[],a.descriptionConfig=[],a.fieldConfig=[],a.selectedTags={tags:[]},a.variables=h},a.getConfiguration=function(){return f.get({accountId:b.id,id:b.configurationId}).$promise.then(function(b){a.configurationName=b.name,a.subjectConfig=b.Subject,a.descriptionConfig=b.Description,a.fieldConfig=b.Field,a.selectedTags={tags:_.map(b.Tags,function(a){return a.id})},e.socket.on("zendesk_field:remove",function(b){_.remove(a.subjectConfig,{id:b.id}),_.remove(a.descriptionConfig,{id:b.id}),_.remove(a.fieldConfig,{id:b.id})})})["catch"](function(a){g.show(a.message,"danger")})},a.getCustomVariables=function(){return i.get().$promise.then(function(b){a.customVariables=b.rows})["catch"](function(a){g.show(a.message,"danger")})},a.getFields=function(){return j.fields({id:b.id}).$promise.then(function(b){a.accountFields=c("zendesk")(b)})["catch"](function(a){g.show(a.message,"danger")})},a.getTags=function(){return k.get().$promise.then(function(b){a.tags=b.rows})["catch"](function(a){g.show(a.message,"danger")})},a.addItem=function(c){switch(c){case"subject":case"description":var d={type:"string",content:""};break;case"field":var d={content:""}}return f.save({accountId:b.id,id:b.configurationId,controller:c},d).$promise.then(function(b){switch(c){case"subject":a.subjectConfig.push(b);break;case"description":a.descriptionConfig.push(b);break;case"field":a.fieldConfig.push(b)}})["catch"](function(a){g.show(a.data.message,"danger")})},a.changeType=function(b){"variable"===b.type?(b.content="",b.variableName=""):"string"===b.type?(b.VariableId=null,b.variableName=""):"customVariable"===b.type&&(b.VariableId=null,b.content=""),a.updateField(b)},a.updateField=function(a){return l.update({accountId:b.id,configurationId:b.configurationId,id:a.id},a).$promise.then(function(){})["catch"](function(){g.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.removeItem=function(a){return l["delete"]({accountId:b.id,configurationId:b.configurationId,id:a.id}).$promise.then(function(){g.show(d.instant("MESSAGE_WELL_DONE")+"!","success")})["catch"](function(){g.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG"),"danger")})},a.changeDescType=function(b){"keyValue"===b.type?(b.content="","string"===b.keyType?(b.VariableId=null,b.variableName=""):"variable"===b.keyType?(b.keyContent="",b.VariableId=null):"customVariable"===b.keyType&&(b.keyContent="",b.variableName="")):"string"===b.type&&(b.VariableId=null,b.variableName="",b.key="",b.keyContent=""),a.updateField(b)},a.changeFieldType=function(b){if(b.content="",b.variableName="",b.nameField="",b.VariableId=null,b.idField){var c=_.find(a.accountFields,"id",b.idField);c&&(c.system_field_options?(b.customField=!1,b.nameField=c.title.toLowerCase()):b.customField=!0)}a.updateField(b)},a.updateTags=function(){return f.update({accountId:b.id,id:b.configurationId,controller:"tags"},a.selectedTags.tags).$promise.then(function(){g.show(d.instant("MESSAGE_WELL_DONE")+".","success")})["catch"](function(a){g.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})},a.getSystemFieldOptions=function(b){if(b){var c=_.find(a.accountFields,"id",b);return c?c.system_field_options?c.system_field_options:null:void 0}}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.view.configurations.view",{url:"/view/:configurationId",templateUrl:"app/zendesk/view/configuration/view/view.html",controller:"ZendeskViewConfigurationViewCtrl"})}]),angular.module("xCallyShuttleApp").controller("ZendeskViewCtrl",["$scope","$stateParams","$translate","xAlert","Modal","ZendeskAccount",function(a,b,c,d,e,f){a.initView=function(){return f.get({id:b.id}).$promise.then(function(b){a.account=b})["catch"](function(a){d.show(a.message,"danger")})},a.updateItem=function(){return f.update({id:b.id},a.account).$promise.then(function(){d.show(c.instant("MESSAGE_WELL_DONE")+".","success")})["catch"](function(){d.show(c.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.view",{url:"/view/:id",templateUrl:"app/zendesk/view/view.html",controller:"ZendeskViewCtrl",resolve:{deps:["$ocLazyLoad",function(a){return a.load([{insertBefore:"#ng_load_plugins_before",files:["assets/css/profile.css","assets/css/tasks.css"]}])}]}}).state("main.zendesk.view.account",{url:"/account",templateUrl:"app/zendesk/view/view.account.html"})}]),angular.module("xCallyShuttleApp").controller("ZendeskWizardCtrl",["$scope","$http","$location","$translate","xAlert","WizardHandler","ZendeskAccount",function(a,b,c,d,e,f,g){a.translate=d,a.initWizard=function(){a.$translate=d,a.forms={},a.item={},a.item.authType="password"},a.next=function(){f.wizard().next()},a.exitValidation=function(a){return a},a.createItem=function(){return g.save(a.item).$promise.then(function(){e.show(d.instant("MESSAGE_WELL_DONE")+".","success"),c.path("/zendesk/list")})["catch"](function(){e.show(d.instant("MESSAGE_SOMETHING_WENT_WRONG")+".","danger")})}}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk.wizard",{url:"/wizard",templateUrl:"app/zendesk/wizard/wizard.html",controller:"ZendeskWizardCtrl"})}]),angular.module("xCallyShuttleApp").factory("ZendeskAccount",["$resource",function(a){return a("/api/zendesk/accounts/:id/:controller",{id:"@id"},{update:{method:"PUT"},fields:{params:{controller:"fields"},isArray:!0},check:{params:{controller:"check"}}})}]).factory("ZendeskConfiguration",["$resource",function(a){return a("/api/zendesk/accounts/:accountId/configurations/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]).factory("ZendeskField",["$resource",function(a){return a("/api/zendesk/accounts/:accountId/configurations/:configurationId/fields/:id/:controller",{id:"@id"},{update:{method:"PUT"}})}]),angular.module("xCallyShuttleApp").config(["$stateProvider",function(a){a.state("main.zendesk",{url:"/zendesk",template:"
","abstract":!0})}]),angular.module("xCallyShuttleApp").service("application",function(){var a={applications:[{name:"Queue",value:"Queue"},{name:"Playback",value:"Playback"},{name:"Dial",value:"Dial"},{name:"Cally-Square IVR",value:"AGI"},{name:"GoTo",value:"Goto"},{name:"Hangup",value:"Hangup"},{name:"Set",value:"Set"},{name:"Custom",value:"custom"},{name:"VoiceMail",value:"Voicemail"}],queueOptions:[{value:"C",name:"APPLICATION_QUEUE_OPTION_C"},{value:"c",name:"APPLICATION_QUEUE_OPTION_c"},{value:"d",name:"APPLICATION_QUEUE_OPTION_d"},{value:"F",name:"APPLICATION_QUEUE_OPTION_F"},{value:"h",name:"APPLICATION_QUEUE_OPTION_h"},{value:"H",name:"APPLICATION_QUEUE_OPTION_H"},{value:"n",name:"APPLICATION_QUEUE_OPTION_n"},{value:"i",name:"APPLICATION_QUEUE_OPTION_i"},{value:"I",name:"APPLICATION_QUEUE_OPTION_I"},{value:"r",name:"APPLICATION_QUEUE_OPTION_r"},{value:"R",name:"APPLICATION_QUEUE_OPTION_R"},{value:"t",name:"APPLICATION_QUEUE_OPTION_t"},{value:"T",name:"APPLICATION_QUEUE_OPTION_T"},{value:"w",name:"APPLICATION_QUEUE_OPTION_w"},{value:"W",name:"APPLICATION_QUEUE_OPTION_W"},{value:"k",name:"APPLICATION_QUEUE_OPTION_k"},{value:"K",name:"APPLICATION_QUEUE_OPTION_K"},{value:"x",name:"APPLICATION_QUEUE_OPTION_x"},{value:"X",name:"APPLICATION_QUEUE_OPTION_X"}],audioOptions:[{value:"skip",name:"APPLICATION_PLAYBACK_OPTION_SKIP"},{value:"noanswer",name:"APPLICATION_PLAYBACK_OPTION_NOANSWER"},{value:"j",name:"APPLICATION_PLAYBACK_OPTION_J"},{value:"say",name:"APPLICATION_PLAYBACK_OPTION_SAY"}],hangupCauses:[{value:"",name:"--"},{value:"1",name:"APPLICATION_HANGUP_CAUSE_1"},{value:"16",name:"APPLICATION_HANGUP_CAUSE_16"},{value:"17",name:"APPLICATION_HANGUP_CAUSE_17"},{value:"18",name:"APPLICATION_HANGUP_CAUSE_18"},{value:"21",name:"APPLICATION_HANGUP_CAUSE_21"},{value:"22",name:"APPLICATION_HANGUP_CAUSE_22"},{value:"27",name:"APPLICATION_HANGUP_CAUSE_27"},{value:"38",name:"APPLICATION_HANGUP_CAUSE_38"},{value:"41",name:"APPLICATION_HANGUP_CAUSE_41"}],intTypes:[{value:"always",name:"APPLICATION_ALWAYS"},{value:"custom",name:"APPLICATION_CUSTOM"},{value:"list",name:"APPLICATION_FROM_LIST"}],checkUnderscore:function(a){return 0===a.indexOf("_")?a:"_"+a}};return{application:a}}),angular.module("xCallyShuttleApp").factory("Auth",["$location","$rootScope","$http","User","$cookieStore","$q",function(a,b,c,d,e,f){var g={};return e.get("token")&&(g=d.me()),{login:function(a,h){var i=h||angular.noop,j=f.defer();return c.post("/auth/local",{name:a.name,password:a.password,remember:a.remember}).success(function(a){return e.put("role",a.role),e.put("token",a.token),e.put("userId",a.userId),g=d.me({},function(){b.$broadcast("login")}),j.resolve(a),i()}).error(function(a){return this.logout(),j.reject(a),i(a)}.bind(this)),j.promise},loginWithToken:function(a,b,c){e.put("token",a),e.put("userId",b),e.put("name",c),g=d.me()},logout:function(){c.put("/api/users/"+g.id,{online:!1}).success(function(){e.remove("role"),e.remove("token"),e.remove("userId"),g={},b.$broadcast("logout")}).error(function(a){return a})},createUser:function(a,b){var c=b||angular.noop;return d.save(a,function(b){return e.put("token",b.token),g=d.me(),c(a)},function(a){return this.logout(),c(a)}.bind(this)).$promise},changePassword:function(a,b,c){var e=c||angular.noop;return d.changePassword({id:g.id},{oldPassword:a,newPassword:b},function(a){return e(null,a)},function(a){return e(a)}).$promise},getCurrentUser:function(){return g},isLoggedIn:function(){return g.hasOwnProperty("role")},isLoggedInAsync:function(a){g.hasOwnProperty("$promise")?g.$promise.then(function(){a(!0)})["catch"](function(){a(!1)}):a(g.hasOwnProperty("role")?!0:!1)},isAdmin:function(){return"admin"===(e.get("role")||g.role)||"user"===(e.get("role")||g.role)},getRole:function(){return g.role},getToken:function(){return e.get("token")},getUserId:function(){return console.log(e.get("userId")),e.get("userId")},getName:function(){return e.get("name")}}}]),angular.module("xCallyShuttleApp").service("automations",function(){var a={voice:{conditions:[],actions:[]},mail:{conditions:[{name:"APPLICATION_STATUS",value:"status",type:"select",arr:[{name:"APPLICATION_STATUS_NEW",value:"NEW"},{name:"APPLICATION_STATUS_OPEN",value:"OPEN"},{name:"APPLICATION_STATUS_CLOSED",value:"CLOSED"}],operators:[{value:"equals",name:"APPLICATION_EQUALS_TO"},{value:"not_equals",name:"APPLICATION_NOT_EQUALS_TO"}]},{name:"APPLICATION_HOURS_SINCE_CREATED",value:"createdAt",type:"input",operators:[{value:"greater_or_equal",name:"APPLICATION_GTE_TO"},{value:"less_or_equal",name:"APPLICATION_LTE_TO"},{value:"greater",name:"APPLICATION_GREATER_THAN"},{value:"less",name:"APPLICATION_LESS_THAN"}]}],actions:[{name:"APPLICATION_STATUS",value:"status"}]},chat:{conditions:[{name:"APPLICATION_STATUS",value:"status",type:"select",arr:[{name:"APPLICATION_STATUS_NEW",value:"NEW"},{name:"APPLICATION_STATUS_OPEN",value:"OPEN"},{name:"APPLICATION_STATUS_CLOSED",value:"CLOSED"}],operators:[{value:"equals",name:"APPLICATION_EQUALS_TO"},{value:"not_equals",name:"APPLICATION_NOT_EQUALS_TO"}]},{name:"APPLICATION_HOURS_SINCE_CREATED",value:"createdAt",type:"input",operators:[{value:"greater_or_equal",name:"APPLICATION_GTE_TO"},{value:"less_or_equal",name:"APPLICATION_LTE_TO"},{value:"greater",name:"APPLICATION_GREATER_THAN"},{value:"less",name:"APPLICATION_LESS_THAN"}]}],actions:[{name:"APPLICATION_STATUS",value:"status"}]},fax:{conditions:[{name:"APPLICATION_STATUS",value:"status",type:"select",arr:[{name:"APPLICATION_STATUS_NEW",value:"NEW"},{name:"APPLICATION_STATUS_OPEN",value:"OPEN"},{name:"APPLICATION_STATUS_CLOSED",value:"CLOSED"}],operators:[{value:"equals",name:"APPLICATION_EQUALS_TO"},{value:"not_equals",name:"APPLICATION_NOT_EQUALS_TO"}]},{name:"APPLICATION_HOURS_SINCE_CREATED",value:"createdAt",type:"input",operators:[{value:"greater_or_equal",name:"APPLICATION_GTE_TO"},{value:"less_or_equal",name:"APPLICATION_LTE_TO"},{value:"greater",name:"APPLICATION_GREATER_THAN"},{value:"less",name:"APPLICATION_LESS_THAN"}]}],actions:[{name:"APPLICATION_STATUS",value:"status"}]}},b=["voice","mail","chat","fax"];return{services:a,channels:b}}),angular.module("xCallyShuttleApp").service("desk_com",function(){var a=[{id:"priority",label:"Priority",custom:!1,data:{choices:[1,2,3,4,5,6,7,8,9,10]}},{id:"status",label:"Status",custom:!1,data:{choices:["new","open","pending","resolved","closed"]}},{id:"type",label:"Type",custom:!1,data:{choices:["chat","twitter","email","qna","facebook","phone"]}}];return{fields:a}}),angular.module("xCallyShuttleApp").controller("FooterController",["$scope","$http",function(a,b){a.year=moment().year(),a.$on("$includeContentLoaded",function(){Layout.initFooter()}),a.initFooter=function(){b.get("/api/settings/info").success(function(b){a.info=b}).error(function(a){console.error(a)})}}]),angular.module("xCallyShuttleApp").controller("HeaderController",["$scope","$rootScope","$location","$state","$http","$notification","Auth","xAlert","socket","ngAudio","settings","toastr","localStorageService","MailReport","ChatReport",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o){a.toggleQuickSidebar=function(){k.layout.pageQuickSidebarOpened=!k.layout.pageQuickSidebarOpened,k.layout.pageQuickSidebarOpened||m.remove("chatRoomId")},a.toogleSidebar=function(){k.layout.pageSidebarClosed=!k.layout.pageSidebarClosed,m.set("sidebarClosed",k.layout.pageSidebarClosed)},a.initHeader=function(){var c=j.load("api/xchatty/assets?resource=notification/xc_blubb.mp3"),d={};"agent"===g.getCurrentUser().role&&(i.socket.on("report_mail:save",function(a){c.play();var d=f("MAIL CHANNEL",{icon:"assets/images/media/channels/mail64.png",body:"NEW Incoming Mail Message!",delay:1e3*a.timeslot});d.$on("click",function(){return n.get({id:a.id,controller1:"accept",controller2:a.uniqueid}).$promise.then(function(){h.show("Mail properly assigned","success"),b.$broadcast("mailMessageEvent",{message:"Mail properly assigned.."})})["catch"](function(a){h.show(a.data.message,"danger")})})}),i.socket.on("report_chat:save",function(a){c.play(),d[a.uniqueid]&&(d[a.uniqueid].close(),delete d[a.uniqueid]),d[a.uniqueid]=f("CHAT CHANNEL",{icon:"assets/images/media/channels/chat64.png",body:"NEW Incoming Chat Visitor!",delay:1e3*a.timeslot}),d[a.uniqueid].$on("click",function(){return o.get({id:a.id,controller1:"accept",controller2:a.uniqueid}).$promise.then(function(){h.show("Chat properly assigned","success"),b.$broadcast("mailMessageEvent",{message:"Chat properly assigned.."})})["catch"](function(a){h.show(a.data.message,"danger")})})}),i.socket.on("chat_message:save",function(a){c.play();var d=m.get("chatRoomId");if((!d||d!==a.ChatRoomId)&&a.UserId&&a.UserId!==g.getCurrentUser().id){var e=f(a.User.fullname,{icon:"assets/images/media/channels/chat64.png",body:a.body.length>35?a.body.substring(0,35)+"...":a.body,delay:1e4});e.$on("click",function(){b.$broadcast("chatMessageEvent",{chatRoomId:a.ChatRoomId})})}}),i.socket.on("user_has_chat_room:save",function(a){c.play(),b.$broadcast("chatGroupEvent",a)})),e({url:"/api/fax/user_has_queues",method:"GET",params:{UserId:g.getCurrentUser().id}}).success(function(b){a.faxQueues=_.map(b,"FaxQueueId"),a.faxQueues.forEach(function(a){i.socket.on("FAX:QUEUE:"+a,function(a,b){var c=f("FAX CHANNEL",{icon:"assets/images/media/channels/telephone124.png",body:"NEW Incoming Fax Message!",delay:1e3*a.timeout});c.$on("click",function(){e.put("/api/fax/rooms/"+a.roomId,{UserId:g.getCurrentUser().id}).success(function(){c.close(),b(g.getCurrentUser().id),l.success("Fax properly assigned","Success",{closeButton:!0,timeOut:5e3})}).error(function(){l.warning("Fax already assigned","Warning",{closeButton:!0,timeOut:5e3})})})})}),i.socket.on("FAX:AGENT:"+g.getCurrentUser().id,function(a,b){var c=f("FAX CHANNEL",{icon:"assets/images/media/channels/telephone124.png",body:"NEW Incoming Fax Message!",delay:1e3*a.timeout});c.$on("click",function(){e.put("/api/fax/rooms/"+a.roomId,{UserId:g.getCurrentUser().id}).success(function(){c.close(),b(g.getCurrentUser().id),l.success("Fax properly assigned","Success",{closeButton:!0,timeOut:5e3})}).error(function(){b(g.getCurrentUser().id),l.warning("Fax already assigned","Warning",{closeButton:!0,timeOut:5e3})})})})}).error(function(a){console.error(a)}),i.socket.on("user_has_fax_queue:save",function(b){b=_.map(b,function(a){return a.UserId=parseInt(a.UserId,10),a}),b=_.find(b,{UserId:g.getCurrentUser().id}),b&&-1===_.indexOf(a.faxQueues,b.FaxQueueId)&&(a.faxQueues.push(b.FaxQueueId),i.socket.on("FAX:QUEUE:"+b.FaxQueueId,function(a,b){var c=f("FAX CHANNEL",{icon:"assets/images/media/channels/telephone124.png",body:"NEW Incoming Fax Message!",delay:1e3*a.timeout});c.$on("click",function(){e.put("/api/fax/rooms/"+a.roomId,{UserId:g.getCurrentUser().id}).success(function(){c.close(),b(g.getCurrentUser().id),l.success("Fax properly assigned","Success",{closeButton:!0,timeOut:5e3})}).error(function(){b(g.getCurrentUser().id),l.warning("Fax already assigned","Warning",{closeButton:!0,timeOut:5e3})})})}))}),i.socket.on("user_has_fax_queue:remove",function(b){_.indexOf(b.where.UserId,g.getCurrentUser().id.toString())>=0&&_.indexOf(a.faxQueues,b.where.FaxQueueId)>=0&&(a.faxQueues=_.remove(a.faxQueues,b.where.FaxQueueId),i.socket.removeAllListeners("FAX:QUEUE:"+b.where.FaxQueueId))})},a.logout=function(){e.get("/auth/local/logout").success(function(){g.logout(),c.path("/login")}).error(function(a){console.error(a)})},a.isActive=function(a){return a===c.path()}}]),angular.module("xCallyShuttleApp").service("interval",function(){var a={months:[{value:"always",name:"APPLICATION_ALWAYS"},{value:"jan",name:"APPLICATION_JANUARY"},{value:"feb",name:"APPLICATION_FEBRUARY"},{value:"mar",name:"APPLICATION_MARCH"},{value:"apr",name:"APPLICATION_APRIL"},{value:"may",name:"APPLICATION_MAY"},{value:"jun",name:"APPLICATION_JUNE"},{value:"jul",name:"APPLICATION_JULY"},{value:"aug",name:"APPLICATION_AUGUST"},{value:"sep",name:"APPLICATION_SEPTEMBER"},{value:"oct",name:"APPLICATION_OCTOBER"},{value:"nov",name:"APPLICATION_NOVEMBER"},{value:"dec",name:"APPLICATION_DECEMBER"}],daysOfWeek:[{value:"always",name:"APPLICATION_ALWAYS"},{value:"mon",name:"APPLICATION_MONDAY"},{value:"tue",name:"APPLICATION_TUESDAY"},{value:"wed",name:"APPLICATION_WEDNESDAY"},{value:"thu",name:"APPLICATION_THURSDAY"},{value:"fri",name:"APPLICATION_FRIDAY"},{value:"sat",name:"APPLICATION_SATURDAY"},{value:"sun",name:"APPLICATION_SUNDAY"}],daysOfMonth:["always",1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31] -};return{interval:a}}),angular.module("xCallyShuttleApp").factory("Modal",["$rootScope","$uibModal",function(a,b){function c(c,d){console.log("openModal",d);var e=a.$new();return c=c||{},d=d||"modal-default",angular.extend(e,c),b.open({templateUrl:"components/modal/delete.html",windowClass:d,scope:e})}return{confirm:{"delete":function(a){return a=a||angular.noop,function(){console.log(Array.prototype.slice.call(arguments));var b,d=Array.prototype.slice.call(arguments),e=d.shift();b=c({modal:{dismissable:!0,title:"Confirm Delete",html:"

Are you sure you want to delete"+(e?" "+e+"":" selected items")+"?

",buttons:[{classes:"btn red",text:"Delete",click:function(a){b.close(a)}},{classes:"btn default",text:"Cancel",click:function(a){b.dismiss(a)}}]}},"over-topbar center"),b.result.then(function(b){a.apply(b,d)})}}}}}]),angular.module("xCallyShuttleApp").controller("QuickSidebarControllerAddModal",["$scope","$uibModalInstance","Agent","items",function(a,b,c,d){a.items=d,a.agents=c.get(function(b){a.agents=b,a.items.forEach(function(b){_.remove(a.agents.rows,{id:b.id})})}),a.selected={items:[]},a.modal={title:"APPLICATION_AGENTS_SELECTION"},a.ok=function(){b.close(_.union(_.map(a.selected.items,"id"),_.map(a.items,"id")))},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").controller("QuickSidebarControllerCloseModal",["$scope","$uibModalInstance",function(a,b){a.modal={title:"APPLICATION_CONFIRM_CLOSE",text:"MESSAGE_ARE_YOU_SURE_YOU_WANT_TO_CLOSE_THE_CHAT"},a.ok=function(){b.close()},a.cancel=function(){b.dismiss()}}]),angular.module("xCallyShuttleApp").controller("QuickSidebarController",["$scope","$rootScope","$window","$http","$uibModal","$log","$timeout","$interval","Auth","Agent","User","ChatRoom","ChatMessage","socket","settings","localStorageService","xAlert","$translate","QuickSidebarFactory",function(a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s){a.emojiMessage={},a.options=s.options,a.message={body:"",user:""};var t=a.currentUser=i.getCurrentUser(),u=function(b){switch(a.messagesTab=!0,o.layout.pageQuickSidebarOpened=!0,p.set("chatRoomId",b.id),p.set("messagesTab",a.messagesTab),a.chatRoom=b,b.type){case"internal":a.currentTab=0;break;case"external":a.currentTab=2,_.find(a.chatRooms,{id:b.id})||a.chatRooms.push(b)}b.Users.length>2&&(a.currentTab=3),g(function(){angular.element("page-quick-sidebar-chat-user-messages").mCustomScrollbar("scrollTo","last")},1500)},v=function(a){console.error(a)};a.$on("$includeContentLoaded",function(){p.get("chatRoomId")&&l.get({id:p.get("chatRoomId")},u,v),p.get("currentTab")&&(a.currentTab=p.get("currentTab"))}),a.agents=j.get({offset:0,limit:1e3},function(){n.syncUpdates("agent",a.agents.rows)}),a.users=k.get({offset:0,limit:1e3},function(){n.syncUpdates("user",a.users.rows)}),a.currentTab=0,a.messagesTab=!1,a.chatRooms=l.me(function(b){a.chatRooms=b},function(a){console.error(a)}),n.socket.on("report_chat:assignment",function(a){a.agentid&&l.get({id:a.chatroomid},u,v)}),n.socket.on("chat_room:save",function(b){if(a.chatRoom&&a.chatRoom.id===b.id){_.merge(a.chatRoom,b);var c=_.find(a.chatRooms,{id:b.id});c&&_.merge(c,b)}}),n.socket.on("chat_message:save",function(b){a.chatRoom&&a.chatRoom.id===b.ChatRoomId&&(a.chatRoom.ChatMessages.push(b),angular.element("page-quick-sidebar-chat-user-messages").mCustomScrollbar("scrollTo","last"))}),n.socket.on("user_has_chat_room:save",function(b){var c=_.findIndex(a.chatRooms,{id:b.id});c>=0?a.chatRooms[c]=b:a.chatRooms.push(b)}),b.$on("chatMessageEvent",function(a,b){l.get({id:b.chatRoomId},u,v)}),b.$on("chatGroupEvent",function(b,c){a.currentTab=3,a.messagesTab=!0,o.layout.pageQuickSidebarOpened=!0,a.chatRoom=c}),a.goToTab=function(b){a.currentTab=b,a.messagesTab=!1,a.chatRoom=null,p.set("currentTab",a.currentTab),p.set("messagesTab",a.messagesTab),p.remove("chatRoomId")},a.goToMessage=function(a,b){a?l.users({users:[t.id,a]},u,v):l.get({id:b},u,v)},a.sendMessage=function(){a.message.body.trim().length&&m.save({ChatRoomId:a.chatRoom.id,body:a.message.body},function(){a.message.body=""},function(a){console.error(a)})},a.goBack=function(){a.messagesTab=!1,a.chatRoom=null,p.set("messagesTab",a.messagesTab),p.remove("chatRoomId")},a.closeChatRoom=function(a,b){var c=e.open({animation:!0,size:b,templateUrl:"components/quickSidebar/modal/close.html",controller:"QuickSidebarControllerCloseModal"});c.result.then(function(){l.update({id:a,status:"CLOSED",completeReason:"agent"}).$promise.then(function(){q.show(r.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){q.show(a.data.message,"danger")})})},a.addAgent=function(b,c){var f=e.open({animation:!0,size:c,templateUrl:"components/quickSidebar/modal/add.html",controller:"QuickSidebarControllerAddModal",resolve:{items:function(){return _.map(a.chatRoom.Users?a.chatRoom.Users:[],function(a){return{id:a.id,fullname:a.fullname}})}}});f.result.then(function(a){d.put("/api/chat/rooms/"+b+"/users",{users:a}).then(function(){q.show(r.instant("MESSAGE_WELL_DONE"),"success")})["catch"](function(a){q.show(a.data.message,"danger")})})};var w=function(){var b=angular.element(c),d=function(){return{h:b.height(),w:b.width()}};a.$watch(d,function(b){a.style={height:b.h-46-46-46+"px"},a.style2={height:b.h-46-46-46-180+"px"}},!0),b.bind("resize",function(){a.$apply()})};w(),a.$on("$destroy",function(){n.unsyncUpdates("agent"),n.unsyncUpdates("user")})}]),angular.module("xCallyShuttleApp").directive("resizeQuickSidebar",["$window",function(a){return function(b){var c=angular.element(a);b.getWindowDimensions=function(){return{h:c.height(),w:c.width()}},b.$watch(b.getWindowDimensions,function(a){b.style={height:a.h-46-46-46+"px"}},!0),c.bind("resize",function(){b.$apply()})}}]),angular.module("xCallyShuttleApp").factory("QuickSidebarFactory",function(){return{options:{link:!0,linkTarget:"_blank",pdf:{embed:!1},image:{embed:!0},audio:{embed:!0},code:{highlight:!0,lineNumbers:!1},basicVideo:!1,video:{embed:!1,width:null,height:null,ytTheme:"dark",details:!1,ytAuthKey:"_nkO9h1A7HlVyiUICO17oA"}}}}),angular.module("xCallyShuttleApp").filter("QuickSidebarFilterUsersGreaterThan",function(){return function(a,b){var c=[];return a.forEach(function(a){var d=0;a.ChatVisitor&&d++,d+=a.Users.length,d>b&&c.push(a)}),c}}).filter("QuickSidebarFilterUsersLowerThan",function(){return function(a,b){var c=[];return a.forEach(function(a){a.Users.length1||_.keys(b.result[0]).length>1?(a.tooManyResults=!0,a.result=null):(a.tooManyResults=!1,null!==_.values(b.result[0])[0]?a.result=_.values(b.result[0])[0].toString():a.result="--"):a.result=null})},a.counterApiCall();var d=b(function(){a.counterApiCall()},1e3*parseInt(a.config.timeout));a.$on("$destroy",function(){b.cancel(d)})}]),angular.module("adf.widget.counter").run(["$templateCache",function(a){a.put("{widgetsPath}/counter/src/edit.html","
{{$select.selected.name}}
{{$select.selected.name}}
{{$select.selected.name}}
"),a.put("{widgetsPath}/counter/src/view.html",'
{{result}}
{{config.details}}
{{config.linkText}}
')}])}(window),function(a,b){angular.module("adf.widget.pie-chart",["adf.provider"]).config(["dashboardProvider",function(a){a.widget("pie-chart",{title:"Pie-Chart",description:"Display a pie-chart starting from DB values",templateUrl:"{widgetsPath}/pie-chart/src/view.html",controller:"apiWidgetPieChartViewCtrl",edit:{templateUrl:"{widgetsPath}/pie-chart/src/edit.html",controller:"apiWidgetPieChartEditCtrl"}})}]).service("apiServicePieChart",["Widget",function(a){return{get:function(b){return a.get({condition:encodeURIComponent(b.condition),table:b.report,fields:b.fields,controller:"piechart"}).$promise.then(function(a){return a})["catch"](function(a){console.log(a)})}}}]).controller("apiWidgetPieChartEditCtrl",["$scope",function(a){function b(){return a.config.fields||(a.config.fields=[{column:"",alias:""}]),a.config.fields}a.config.reportTables=[{name:"Agents",value:"report_agent"},{name:"Calls",value:"report_call"},{name:"Dials",value:"report_dial"},{name:"Queues",value:"report_queue"},{name:"Users",value:"users"},{name:"Chat Sessions",value:"report_chat_session"},{name:"Mail Sessions",value:"report_mail_session"}],a.config.timeout=a.config.timeout?a.config.timeout:1,a.config.fields=a.config.fields?a.config.fields:[{column:"",alias:""}],a.addField=function(){b().push({})},a.removeField=function(a){b().splice(a,1)}}]).controller("apiWidgetPieChartViewCtrl",["$scope","$interval","apiServicePieChart",function(a,b,c){a.config.timeout=a.config.timeout?a.config.timeout:1,a.pieChartApiCall=function(){a.config.report&&a.config.fields.length&&""!==a.config.fields[0].column&&""!==a.config.fields[0].alias&&c.get(a.config).then(function(b){if(b&&b.result&&1===b.result.length){a.labels=[],a.data=[];for(var c in b.result[0])a.labels.push(c),a.data.push(b.result[0][c])}else a.labels=[],a.data=[]})},a.pieChartApiCall();var d=b(function(){a.pieChartApiCall()},1e3*parseInt(a.config.timeout));a.$on("$destroy",function(){b.cancel(d)})}]),angular.module("adf.widget.pie-chart").run(["$templateCache",function(a){a.put("{widgetsPath}/pie-chart/src/edit.html",'
{{$select.selected.name}}
as
'),a.put("{widgetsPath}/pie-chart/src/view.html",'
')}])}(window),function(a,b){angular.module("adf.widget.table",["adf.provider"]).value("apiServiceUrlTable","/api/widgets/table").config(["dashboardProvider",function(a){a.widget("table",{title:"Table",description:"Show tabbed results from db",templateUrl:"{widgetsPath}/table/src/view.html",controller:"apiWidgetTableViewCtrl",edit:{templateUrl:"{widgetsPath}/table/src/edit.html",controller:"apiWidgetTableEditCtrl"}})}]).service("apiServiceTable",["$q","$http","apiServiceUrlTable",function(a,b,c){return{get:function(d){var e=a.defer();return b.get(c,{params:{condition:encodeURIComponent(d.condition),table:d.report,fields:d.fields}}).success(function(a){a?e.resolve(a):e.reject()}).error(function(a){console.log(a),e.reject()}),e.promise}}}]).controller("apiWidgetTableEditCtrl",["$scope",function(a){function b(){return a.config.fields||(a.config.fields=[{column:"",alias:""}]),a.config.fields}a.config.reportTables=[{name:"Agents",value:"agent"},{name:"Calls",value:"call"},{name:"Dials",value:"dial"},{name:"Members",value:"member"},{name:"Queues",value:"queue"}],a.config.timeout=a.config.timeout?a.config.timeout:1,a.config.height=a.config.height?a.config.height:350,a.config.fields=a.config.fields?a.config.fields:[{column:"",alias:""}],a.addField=function(){b().push({})},a.removeField=function(a){b().splice(a,1)}}]).controller("apiWidgetTableViewCtrl",["$scope","$interval","apiServiceTable",function(a,b,c){a.config.timeout=a.config.timeout?a.config.timeout:1,a.config.height=a.config.height?a.config.height:350,a.config.style={"max-height":a.config.height+"px",overflow:"scroll"},a.tableApiCall=function(){a.config.condition&&a.config.report&&a.config.fields.length&&""!==a.config.fields[0].column&&""!==a.config.fields[0].alias&&c.get(a.config).then(function(b){a.results=b})},a.tableApiCall();var d=b(function(){a.tableApiCall()},1e3*parseInt(a.config.timeout));a.$on("$destroy",function(){b.cancel(d)})}]),angular.module("adf.widget.table").run(["$templateCache",function(a){a.put("{widgetsPath}/table/src/edit.html",'
{{$select.selected.name}}
as
'),a.put("{widgetsPath}/table/src/view.html",'
{{field.alias}}
{{result[field.alias]}}
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
')}])}(window),function(){angular.module("pdf",[]).directive("ngPdf",["$window",function(a){return{restrict:"E",templateUrl:function(a,b){return b.templateUrl?b.templateUrl:"partials/viewer.html"},link:function(b,c,d){var e=d.pdfUrl,f=null,g=d.page?d.page:1,h=d.scale>0?d.scale:1,i=c.find("canvas"),j=i[0],k=j.getContext("2d"),l=angular.element(a);l.on("scroll",function(){b.$apply(function(){b.scroll=l[0].scrollY})}),PDFJS.disableWorker=!0,b.pageNum=g,b.renderPage=function(a){f.getPage(a).then(function(a){var e,f,g,i={};"page-fit"!==d.scale||h?e=a.getViewport(h):(e=a.getViewport(1),f=c[0].clientWidth/e.width,g=c[0].clientHeight/e.height,h=Math.min(f,g)),j.height=e.height,j.width=e.width,i={canvasContext:k,viewport:e},a.render(i).promise.then(function(){"function"==typeof b.onPageRender&&b.onPageRender()})})},b.goPrevious=function(){b.pageToDisplay<=1||(b.pageNum=parseInt(b.pageNum)-1)},b.goNext=function(){b.pageToDisplay>=f.numPages||(b.pageNum=parseInt(b.pageNum)+1)},b.zoomIn=function(){return h=parseFloat(h)+.2,b.renderPage(b.pageToDisplay),h},b.zoomOut=function(){return h=parseFloat(h)-.2,b.renderPage(b.pageToDisplay),h},b.changePage=function(){b.renderPage(b.pageToDisplay)},b.rotate=function(){"rotate0"===j.getAttribute("class")?j.setAttribute("class","rotate90"):"rotate90"===j.getAttribute("class")?j.setAttribute("class","rotate180"):"rotate180"===j.getAttribute("class")?j.setAttribute("class","rotate270"):j.setAttribute("class","rotate0")},PDFJS.getDocument(e,null,null,b.onProgress).then(function(a){"function"==typeof b.onLoad&&b.onLoad(),f=a,b.renderPage(b.pageToDisplay),b.$apply(function(){b.pageCount=a.numPages})},function(a){a&&"function"==typeof b.onError&&b.onError(a)}),b.$watch("pageNum",function(a){b.pageToDisplay=parseInt(a),null!==f&&b.renderPage(b.pageToDisplay)})}}}])}();var Metronic=function(){var a,b=!1,c=!1,d=!1,e=!1,f=[],g="assets/",h="img/",i="plugins/",j="css/",k={blue:"#89C4F4",red:"#F3565D",green:"#1bbc9b",purple:"#9b59b6",grey:"#95a5a6",yellow:"#F8CB00"},l=function(){"rtl"===$("body").css("direction")&&(b=!0),c=!!navigator.userAgent.match(/MSIE 8.0/),d=!!navigator.userAgent.match(/MSIE 9.0/),e=!!navigator.userAgent.match(/MSIE 10.0/),e&&$("html").addClass("ie10"),(e||d||c)&&$("html").addClass("ie")},m=function(){for(var a=0;a .portlet-title > .tools > a.remove",function(a){a.preventDefault();var b=$(this).closest(".portlet");$("body").hasClass("page-portlet-fullscreen")&&$("body").removeClass("page-portlet-fullscreen"),b.find(".portlet-title .fullscreen").tooltip("destroy"),b.find(".portlet-title > .tools > .reload").tooltip("destroy"), -b.find(".portlet-title > .tools > .remove").tooltip("destroy"),b.find(".portlet-title > .tools > .config").tooltip("destroy"),b.find(".portlet-title > .tools > .collapse, .portlet > .portlet-title > .tools > .expand").tooltip("destroy"),b.remove()}),$("body").on("click",".portlet > .portlet-title .fullscreen",function(a){a.preventDefault();var b=$(this).closest(".portlet");if(b.hasClass("portlet-fullscreen"))$(this).removeClass("on"),b.removeClass("portlet-fullscreen"),$("body").removeClass("page-portlet-fullscreen"),b.children(".portlet-body").css("height","auto");else{var c=Metronic.getViewPort().height-b.children(".portlet-title").outerHeight()-parseInt(b.children(".portlet-body").css("padding-top"))-parseInt(b.children(".portlet-body").css("padding-bottom"));$(this).addClass("on"),b.addClass("portlet-fullscreen"),$("body").addClass("page-portlet-fullscreen"),b.children(".portlet-body").css("height",c)}}),$("body").on("click",".portlet > .portlet-title > .tools > a.reload",function(a){a.preventDefault();var b=$(this).closest(".portlet").children(".portlet-body"),c=$(this).attr("data-url"),d=$(this).attr("data-error-display");c?(Metronic.blockUI({target:b,animate:!0,overlayColor:"none"}),$.ajax({type:"GET",cache:!1,url:c,dataType:"html",success:function(a){Metronic.unblockUI(b),b.html(a)},error:function(a,c,e){Metronic.unblockUI(b);var f="Error on reloading the content. Please check your connection and try again.";"toastr"==d&&toastr?toastr.error(f):"notific8"==d&&$.notific8?($.notific8("zindex",11500),$.notific8(f,{theme:"ruby",life:3e3})):alert(f)}})):(Metronic.blockUI({target:b,animate:!0,overlayColor:"none"}),window.setTimeout(function(){Metronic.unblockUI(b)},1e3))}),$('.portlet .portlet-title a.reload[data-load="true"]').click(),$("body").on("click",".portlet > .portlet-title > .tools > .collapse, .portlet .portlet-title > .tools > .expand",function(a){a.preventDefault()})},p=function(){if($().uniform){var a=$("input[type=checkbox]:not(.toggle, .make-switch, .icheck), input[type=radio]:not(.toggle, .star, .make-switch, .icheck)");a.size()>0&&a.each(function(){0===$(this).parents(".checker").size()&&$(this).show()})}},q=function(){$().iCheck&&$(".icheck").each(function(){var a=$(this).attr("data-checkbox")?$(this).attr("data-checkbox"):"icheckbox_minimal-grey",b=$(this).attr("data-radio")?$(this).attr("data-radio"):"iradio_minimal-grey";a.indexOf("_line")>-1||b.indexOf("_line")>-1?$(this).iCheck({checkboxClass:a,radioClass:b,insert:'
'+$(this).attr("data-label")}):$(this).iCheck({checkboxClass:a,radioClass:b})})},r=function(){$().bootstrapSwitch&&$(".make-switch").bootstrapSwitch()},s=function(){$().confirmation&&$("[data-toggle=confirmation]").confirmation({container:"body",btnOkClass:"btn-xs btn-success",btnCancelClass:"btn-xs btn-danger"})},t=function(){$("body").on("shown.bs.collapse",".accordion.scrollable",function(a){Metronic.scrollTo($(a.target))})},u=function(){if(location.hash){var a=location.hash.substr(1);$('a[href="#'+a+'"]').parents(".tab-pane:hidden").each(function(){var a=$(this).attr("id");$('a[href="#'+a+'"]').click()}),$('a[href="#'+a+'"]').click()}},v=function(){$("body").on("hide.bs.modal",function(){$(".modal:visible").size()>1&&$("html").hasClass("modal-open")===!1?$("html").addClass("modal-open"):$(".modal:visible").size()<=1&&$("html").removeClass("modal-open")}),$("body").on("show.bs.modal",".modal",function(){$(this).hasClass("modal-scroll")&&$("body").addClass("modal-open-noscroll")}),$("body").on("hide.bs.modal",".modal",function(){$("body").removeClass("modal-open-noscroll")}),$("body").on("hidden.bs.modal",".modal:not(.modal-cached)",function(){$(this).removeData("bs.modal")})},w=function(){$(".tooltips").tooltip(),$(".portlet > .portlet-title .fullscreen").tooltip({container:"body",title:"Fullscreen"}),$(".portlet > .portlet-title > .tools > .reload").tooltip({container:"body",title:"Reload"}),$(".portlet > .portlet-title > .tools > .remove").tooltip({container:"body",title:"Remove"}),$(".portlet > .portlet-title > .tools > .config").tooltip({container:"body",title:"Settings"}),$(".portlet > .portlet-title > .tools > .collapse, .portlet > .portlet-title > .tools > .expand").tooltip({container:"body",title:"Collapse/Expand"})},x=function(){$("body").on("click",".dropdown-menu.hold-on-click",function(a){a.stopPropagation()})},y=function(){$("body").on("click",'[data-close="alert"]',function(a){$(this).parent(".alert").hide(),$(this).closest(".note").hide(),a.preventDefault()}),$("body").on("click",'[data-close="note"]',function(a){$(this).closest(".note").hide(),a.preventDefault()}),$("body").on("click",'[data-remove="note"]',function(a){$(this).closest(".note").remove(),a.preventDefault()})},z=function(){$('[data-hover="dropdown"]').not(".hover-initialized").each(function(){$(this).dropdownHover(),$(this).addClass("hover-initialized")})},A=function(){$(".popovers").popover(),$(document).on("click.bs.popover.data-api",function(b){a&&a.popover("hide")})},B=function(){Metronic.initSlimScroll(".scroller")},C=function(){jQuery.fancybox&&$(".fancybox-button").size()>0&&$(".fancybox-button").fancybox({groupAttr:"data-rel",prevEffect:"none",nextEffect:"none",closeBtn:!0,helpers:{title:{type:"inside"}}})},D=function(){(c||d)&&$("input[placeholder]:not(.placeholder-no-fix), textarea[placeholder]:not(.placeholder-no-fix)").each(function(){var a=$(this);""===a.val()&&""!==a.attr("placeholder")&&a.addClass("placeholder").val(a.attr("placeholder")),a.focus(function(){a.val()==a.attr("placeholder")&&a.val("")}),a.blur(function(){(""===a.val()||a.val()==a.attr("placeholder"))&&a.val(a.attr("placeholder"))})})},E=function(){$().select2&&$(".select2me").select2({placeholder:"Select"})};return{init:function(){l(),n(),p(),q(),r(),B(),C(),E(),o(),y(),x(),u(),w(),A(),t(),v(),s(),D()},initAjax:function(){p(),q(),r(),z(),B(),E(),C(),x(),w(),A(),t(),s()},initComponents:function(){this.initAjax()},setLastPopedPopover:function(b){a=b},addResizeHandler:function(a){f.push(a)},runResizeHandlers:function(){m()},scrollTo:function(a,b){var c=a&&a.size()>0?a.offset().top:0;a&&($("body").hasClass("page-header-fixed")&&(c-=$(".page-header").height()),c+=b?b:-1*a.height()),$("html,body").animate({scrollTop:c},"slow")},initSlimScroll:function(a){$(a).each(function(){if(!$(this).attr("data-initialized")){var a;a=$(this).attr("data-height")?$(this).attr("data-height"):$(this).css("height"),$(this).slimScroll({allowPageScroll:!0,size:"7px",color:$(this).attr("data-handle-color")?$(this).attr("data-handle-color"):"#bbb",wrapperClass:$(this).attr("data-wrapper-class")?$(this).attr("data-wrapper-class"):"slimScrollDiv",railColor:$(this).attr("data-rail-color")?$(this).attr("data-rail-color"):"#eaeaea",position:b?"left":"right",height:a,alwaysVisible:"1"==$(this).attr("data-always-visible")?!0:!1,railVisible:"1"==$(this).attr("data-rail-visible")?!0:!1,disableFadeOut:!0}),$(this).attr("data-initialized","1")}})},destroySlimScroll:function(a){$(a).each(function(){if("1"===$(this).attr("data-initialized")){$(this).removeAttr("data-initialized"),$(this).removeAttr("style");var a={};$(this).attr("data-handle-color")&&(a["data-handle-color"]=$(this).attr("data-handle-color")),$(this).attr("data-wrapper-class")&&(a["data-wrapper-class"]=$(this).attr("data-wrapper-class")),$(this).attr("data-rail-color")&&(a["data-rail-color"]=$(this).attr("data-rail-color")),$(this).attr("data-always-visible")&&(a["data-always-visible"]=$(this).attr("data-always-visible")),$(this).attr("data-rail-visible")&&(a["data-rail-visible"]=$(this).attr("data-rail-visible")),$(this).slimScroll({wrapperClass:$(this).attr("data-wrapper-class")?$(this).attr("data-wrapper-class"):"slimScrollDiv",destroy:!0});var b=$(this);$.each(a,function(a,c){b.attr(a,c)})}})},scrollTop:function(){Metronic.scrollTo()},blockUI:function(a){a=$.extend(!0,{},a);var b="";if(b=a.animate?'
':a.iconOnly?'
':a.textOnly?'
  '+(a.message?a.message:"LOADING...")+"
":'
  '+(a.message?a.message:"LOADING...")+"
",a.target){var c=$(a.target);c.height()<=$(window).height()&&(a.cenrerY=!0),c.block({message:b,baseZ:a.zIndex?a.zIndex:1e3,centerY:void 0!==a.cenrerY?a.cenrerY:!1,css:{top:"10%",border:"0",padding:"0",backgroundColor:"none"},overlayCSS:{backgroundColor:a.overlayColor?a.overlayColor:"#555",opacity:a.boxed?.05:.1,cursor:"wait"}})}else $.blockUI({message:b,baseZ:a.zIndex?a.zIndex:1e3,css:{border:"0",padding:"0",backgroundColor:"none"},overlayCSS:{backgroundColor:a.overlayColor?a.overlayColor:"#555",opacity:a.boxed?.05:.1,cursor:"wait"}})},unblockUI:function(a){a?$(a).unblock({onUnblock:function(){$(a).css("position",""),$(a).css("zoom","")}}):$.unblockUI()},startPageLoading:function(a){a&&a.animate?($(".page-spinner-bar").remove(),$("body").append('
')):($(".page-loading").remove(),$("body").append('
  '+(a&&a.message?a.message:"Loading...")+"
"))},stopPageLoading:function(){$(".page-loading, .page-spinner-bar").remove()},alert:function(a){a=$.extend(!0,{container:"",place:"append",type:"success",message:"",close:!0,reset:!0,focus:!0,closeInSeconds:0,icon:""},a);var b=Metronic.getUniqueID("Metronic_alert"),c='
'+(a.close?'':"")+(""!==a.icon?' ':"")+a.message+"
";return a.reset&&$(".Metronic-alerts").remove(),a.container?"append"==a.place?$(a.container).append(c):$(a.container).prepend(c):$("body").hasClass("page-container-bg-solid")?$(".page-title").after(c):$(".page-bar").size()>0?$(".page-bar").after(c):$(".page-breadcrumb").after(c),a.focus&&Metronic.scrollTo($("#"+b)),a.closeInSeconds>0&&setTimeout(function(){$("#"+b).remove()},1e3*a.closeInSeconds),b},initUniform:function(a){a?$(a).each(function(){0===$(this).parents(".checker").size()&&($(this).show(),$(this).uniform())}):p()},updateUniform:function(a){$.uniform.update(a)},initFancybox:function(){C()},getActualVal:function(a){return a=$(a),a.val()===a.attr("placeholder")?"":a.val()},getURLParameter:function(a){var b,c,d=window.location.search.substring(1),e=d.split("&");for(b=0;b a").each(function(){var a=$(this).attr("href").toLowerCase();return a.length>1&&d.substr(1,a.length-1)==a.substr(1)?void(b=$(this)):void 0}),b&&0!=b.size()&&"javascript:;"!==b.attr("href").toLowerCase()&&"#"!==b.attr("href").toLowerCase()){parseInt(e.data("slide-speed")),e.data("keep-expanded");e.find("li.active").removeClass("active"),e.find("li > a > .selected").remove(),e.hasClass("page-sidebar-menu-hover-submenu")===!1?e.find("li.open").each(function(){0===$(this).children(".sub-menu").size()&&($(this).removeClass("open"),$(this).find("> a > .arrow.open").removeClass("open"))}):e.find("li.open").removeClass("open"),b.parents("li").each(function(){$(this).addClass("active"),$(this).find("> a > span.arrow").addClass("open"),1===$(this).parent("ul.page-sidebar-menu").size()&&$(this).find("> a").append(''),1===$(this).children("ul.sub-menu").size()&&$(this).addClass("open")}),"click"===a&&Metronic.getViewPort().width a",function(a){var b=$(this).next().hasClass("sub-menu");if(!(Metronic.getViewPort().width>=c&&1===$(this).parents(".page-sidebar-menu-hover-submenu").size())){if(b===!1)return void(Metronic.getViewPort().width a.ajaxify",function(a){a.preventDefault(),Metronic.scrollTop();var b=$(this).attr("href"),d=jQuery(".page-sidebar ul"),e=($(".page-content"),$(".page-content .page-content-body"));d.children("li.active").removeClass("active"),d.children("arrow.open").removeClass("open"),$(this).parents("li").each(function(){$(this).addClass("active"),$(this).children("a > span.arrow").addClass("open")}),$(this).parents("li").addClass("active"),Metronic.getViewPort().width li.open > a").click(),Metronic.stopPageLoading(),e.html(a),Layout.fixContentHeight(),Metronic.initAjax()},error:function(a,b,c){Metronic.stopPageLoading(),e.html("

Could not load the requested content.

")}})}),jQuery(".page-content").on("click",".ajaxify",function(a){a.preventDefault(),Metronic.scrollTop();var b=$(this).attr("href"),d=($(".page-content"),$(".page-content .page-content-body"));Metronic.startPageLoading(),Metronic.getViewPort().widthCould not load the requested content."),Metronic.stopPageLoading()}})}),i(),$(".page-sidebar").on("click",".sidebar-search .remove",function(a){a.preventDefault(),$(".sidebar-search").removeClass("open")}),$(".page-sidebar .sidebar-search").on("keypress","input.form-control",function(a){return 13==a.which?($(".sidebar-search").submit(),!1):void 0}),0!==$(".sidebar-search").size()&&($(".sidebar-search .input-group").on("click",function(a){a.stopPropagation()}),$("body").on("click",function(){$(".sidebar-search").hasClass("open")&&$(".sidebar-search").removeClass("open")}))},g=function(){var a=Metronic.getViewPort().height-$(".page-header").outerHeight();return $("body").hasClass("page-footer-fixed")&&(a-=$(".page-footer").outerHeight()),a},h=function(){var a=$(".page-sidebar-menu");return Metronic.destroySlimScroll(a),0===$(".page-sidebar-fixed").size()?void d():void(Metronic.getViewPort().width>=c&&(a.attr("data-height",g()),Metronic.initSlimScroll(a),d()))},i=function(){var a=$("body");a.hasClass("page-sidebar-fixed")&&$(".page-sidebar").on("mouseenter",function(){a.hasClass("page-sidebar-closed")&&$(this).find(".page-sidebar-menu").removeClass("page-sidebar-menu-closed")}).on("mouseleave",function(){a.hasClass("page-sidebar-closed")&&$(this).find(".page-sidebar-menu").addClass("page-sidebar-menu-closed")})},j=function(){$("body");$.cookie&&"1"===$.cookie("sidebar_closed")&&Metronic.getViewPort().width>=c?($("body").addClass("page-sidebar-closed"),$(".page-sidebar-menu").addClass("page-sidebar-menu-closed")):$.cookie&&$.cookie("sidebar_closed","0")},k=function(){$(".page-header").on("click",'.hor-menu a[data-toggle="tab"]',function(a){a.preventDefault();var b=$(".hor-menu .nav"),c=b.find("li.current");$("li.active",c).removeClass("active"),$(".selected",c).remove();var d=$(this).parents("li").last();d.addClass("current"),d.find("a:first").append('')}),$(".page-header").on("click",".search-form",function(a){$(this).addClass("open"),$(this).find(".form-control").focus(),$(".page-header .search-form .form-control").on("blur",function(a){$(this).closest(".search-form").removeClass("open"),$(this).unbind("blur")})}),$(".page-header").on("keypress",".hor-menu .search-form .form-control",function(a){return 13==a.which?($(this).closest(".search-form").submit(),!1):void 0}),$(".page-header").on("mousedown",".search-form.open .submit",function(a){a.preventDefault(),a.stopPropagation(),$(this).closest(".search-form").submit()}),$('[data-hover="megamenu-dropdown"]').not(".hover-initialized").each(function(){$(this).dropdownHover(),$(this).addClass("hover-initialized")}),$(document).on("click",".mega-menu-dropdown .dropdown-menu",function(a){a.stopPropagation()})},l=function(){$("body").on("shown.bs.tab",'a[data-toggle="tab"]',function(){d()})},m=function(){var a=300,b=500;navigator.userAgent.match(/iPhone|iPad|iPod/i)?$(window).bind("touchend touchcancel touchleave",function(c){$(this).scrollTop()>a?$(".scroll-to-top").fadeIn(b):$(".scroll-to-top").fadeOut(b)}):$(window).scroll(function(){$(this).scrollTop()>a?$(".scroll-to-top").fadeIn(b):$(".scroll-to-top").fadeOut(b)}),$(".scroll-to-top").click(function(a){return a.preventDefault(),$("html, body").animate({scrollTop:0},b),!1})},n=function(){var a,b=$(".full-height-content");if(a=Metronic.getViewPort().height-$(".page-header").outerHeight(!0)-$(".page-footer").outerHeight(!0)-$(".page-title").outerHeight(!0)-$(".page-bar").outerHeight(!0),b.hasClass("portlet")){var d=b.find(".portlet-body");if(Metronic.getViewPort().width\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_EXTRACTED_REPORTS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n\n'),a.put("app/analytic/metric/list/create.modal.html",'\n\n\n'),a.put("app/analytic/metric/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_METRICS\' | translate }} \n
\n
\n \n
\n \n
\n \n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/analytic/metric/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{metric.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/analytic/metric/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_METRIC\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'), -a.put("app/analytic/report/list/copy.modal.html",'\n\n\n'),a.put("app/analytic/report/list/create.modal.html",'\n\n\n'),a.put("app/analytic/report/list/extract.modal.html",'\n\n\n'),a.put("app/analytic/report/list/list.html",'\n
\n
\n \n
\n \n
\n
\n
\n \n {{ \'APPLICATION_FOLDERS\' | translate }} \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_REPORTS\' | translate }} - {{selectedNode}}\n
\n
\n \n
\n \n \n {{\'APPLICATION_IMPORT_FROM_JSON\' | translate}}\n \n \n
\n
\n \n
\n
\n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n \n
\n
\n
\n
\n\n'),a.put("app/analytic/report/list/preview.modal.html",'\n\n\n'),a.put("app/analytic/report/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{report.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/analytic/report/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_REPORT\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n\n
\n \n
\n
\n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n\n\n \n
\n\n
\n \n
\n
\n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n
\n \n {{ \'APPLICATION_FIELDS\' | translate}} \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{ \'APPLICATION_FIELD\' | translate }} / {{ \'APPLICATION_METRIC\' | translate }}{{ \'APPLICATION_ALIAS\' | translate }}{{ \'APPLICATION_FUNCTION\' | translate }}{{ \'APPLICATION_GROUP_BY\' | translate }}{{ \'APPLICATION_ORDER_BY\' | translate }}
\n \n
\n \n \n \n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n \n
\n \n
\n \n \n {{$select.selected.name | translate}}\n \n {{$translate.instant(groupBy.name)}}\n \n \n
\n \n
\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n
\n \n
\n \n \n \n
\n {{ \'MESSAGE_ADD_A_FIELD\' | translate }}\n
\n \n \n
\n
\n
\n
\n \n {{ \'APPLICATION_CONDITIONS\' | translate}} \n
\n
\n
\n Output
\n \n
\n\n \n
\n \n
\n
\n
\n
\n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/channels/chat/offline/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_VISITORS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/offline/view/view.detail.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_DETAIL\' | translate}}\n
\n
\n
\n
\n
\n

\n {{\'APPLICATION_MESSAGE\' | translate}}\n
\n

\n
\n \n
\n

\n {{chatVisitor.ChatEnquiry.text}}\n

\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/chat/offline/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{chatVisitor.ChatEnquiry.email}}\n
\n
\n {{chatVisitor.ChatEnquiry.username}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/online/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_VISITORS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/online/view/view.detail.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_DETAIL\' | translate}}\n
\n
\n \n
\n
\n
\n'), -a.put("app/channels/chat/online/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{chatRoom.ChatVisitor.email}}\n
\n
\n {{chatRoom.ChatVisitor.fullname}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/preview/preview.html",'\n
\n
\n \n \n \n \n \n {{statePreview.state == \'online\' ? chatWebsite.header_online : chatWebsite.header_offline}}\n
\n
\n
\n \n
\n
\n

\n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n
\n
\n \n
\n
\n

{{chatWebsite.rating_message}}

\n
\n
\n \n \n
\n
\n \n \n
\n \n \n
\n
\n \n
\n
\n'),a.put("app/channels/chat/queue/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/chat/queue/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_QUEUES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/queue/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/chat/queue/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{queue.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/queue/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{$select.selected.toUpperCase()}}\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n'),a.put("app/channels/chat/realtime/view/agent/agent.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/realtime/view/agent/agent.modal.info.html",'\n\n\n'),a.put("app/channels/chat/realtime/view/agent/queue.modal.add.html",'\n\n\n'),a.put("app/channels/chat/realtime/view/queue/queue.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'), -a.put("app/channels/chat/realtime/view/session/session.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/realtime/view/view.html",'\n\n\n'),a.put("app/channels/chat/visitor/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_VISITORS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/visitor/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{chatVisitor.fullname}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/visitor/view/view.profile.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_PROFILE\' | translate}}\n
\n
\n \n
\n
\n
\n'),a.put("app/channels/chat/website/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_WEB_SITES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/website/view/action/list/list.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/chat/website/view/action/view/view.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACTION\' | translate }} \n
\n
\n
\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n
\n \n
\n \n \n {{$select.selected.fullname}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n \n
\n \n \n {{ $select.selected.name | translate }}\n \n {{ intType.name | translate }}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n
\n
\n \n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate}}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate }}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{ $select.selected.name}}\n \n {{ interval.name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/chat/website/view/action/wizard/wizard.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACTION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n
\n \n
\n \n \n {{$select.selected.fullname}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n \n
\n \n \n {{ $select.selected.name | translate }}\n \n {{ intType.name | translate }}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n
\n
\n \n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate}}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate }}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{ $select.selected.name}}\n \n {{ interval.name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n\n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'), -a.put("app/channels/chat/website/view/embedding/view/view.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_EMBEDDING\' | translate}}\n
\n \n
\n
\n
\n
\n

{{\'APPLICATION_EMBED_SNIPPET\' | translate}}

\n

\n {{\'MESSAGE_EMBED_SNIPPET\' | translate}}\n

\n
\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/channels/chat/website/view/form/view/view.html",'
\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_FIELDS_SELECTED\' | translate }}\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_FIELDS_AVAILABLE\' | translate }}\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_FIELDS_SELECTED\' | translate }}\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_FIELDS_AVAILABLE\' | translate }}\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/channels/chat/website/view/proactive/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/chat/website/view/proactive/list/list.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_PROACTIVE_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/chat/website/view/snippet/view/view.html",'
\n
\n
\n \n
\n
\n
\n
\n\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{$translate.instant(\'APPLICATION_\' + $select.selected.toUpperCase())}}\n \n
\n
\n
\n
\n \n\n \n
\n \n \n \n {{$select.selected ? \'On\' : \'Off\'}}\n \n
\n
\n
\n
\n \n\n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n {{$select.selected ? \'On\' : \'Off\'}}\n \n
\n
\n
\n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n

{{\'APPLICATION_ONLINE_STATE\' | translate}}

\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n

{{\'APPLICATION_RATING_STATE\' | translate}}

\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n

{{\'APPLICATION_OFFLINE_STATE\' | translate}}

\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n {{\'MESSAGE_REMEMBER_SMTP_SERVICE_ACCOUNT\' | translate}}.\n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n
\n
\n \n
\n \n \n \n {{$select.selected}}\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n'), -a.put("app/channels/chat/website/view/view.html",'\n\n\n'),a.put("app/channels/chat/website/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_WEB_SITE\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n\n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{$translate.instant(\'APPLICATION_\' + $select.selected.toUpperCase())}}\n \n
\n
\n
\n
\n \n\n \n
\n \n \n {{$select.selected ? \'On\' : \'Off\'}}\n \n
\n
\n
\n
\n \n\n\n \n
\n
\n\n \n
\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n
\n\n \n
\n \n \n {{$select.selected ? \'On\' : \'Off\'}}\n \n
\n
\n
\n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/account/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNTS\' | translate }} \n
\n \n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_PHONE\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{faxAccount.name}}{{faxAccount.description}}{{faxAccount.phone}}\n \n {{ \'APPLICATION_EDIT\' | translate }}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No fax account available\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/account/view/view.applications.html",'
\n
\n\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n {{$select.selected | uppercase}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n \n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'), -a.put("app/channels/fax/account/view/view.html",'\n
\n
\n \n\n\n\n\n \n
\n \n
\n \n
\n \n
\n \n\n \n
\n
\n {{ account.name || account.description }}\n
\n
\n {{ account.phone }}\n
\n
\n \n\n \n \n \n
\n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/account/view/view.routes.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ROUTES\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_APPLICATION\' | translate}}{{\'APPLICATION_ARGUMENTS\' | translate}}{{\'APPLICATION_TIMEOUT\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{application.app}} {{getAppdata(application.app, application.appdata)}}{{application.timeout}}\n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No applications available\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/fax/account/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/fax/account/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/inbox/inbox.html",'\n\n\n
\n
\n
\n
\n'),a.put("app/channels/fax/inbox/incoming/incoming.html",'\n
\n \n
\n

Inbox

\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n \n
\n
\n \n \n \n \n
\n \n {{$select.selected}}\n \n \n \n \n
\n
\n
\n \n \n {{faxRoom.from}}\n \n {{faxRoom.MailAccount.description ? faxRoom.MailAccount.description : faxRoom.MailAccount.name}}\n \n {{faxRoom.status | uppercase}} \n \n {{faxRoom.User.fullname}} \n {{\'APPLICATION_UNASSIGNED\' | translate}} \n \n \n
\n {{\'MESSAGE_NO_AVAILABLE_MESSAGES\' | translate}}\n
\n \n
\n
\n
\n'),a.put("app/channels/fax/inbox/room/room.html",'\n
\n
\n \n \n \n
\n
\n
\n
\n
    \n
  • \n \n
    \n \n \n {{\'APPLICATION_FROM\' | translate}}: \n {{faxMessage.From.fullname}} \n <{{faxMessage.From.phone}}> \n
    \n {{\'APPLICATION_TO\' | translate}}: \n {{faxMessage.To.fullname}} \n <{{faxMessage.To.phone}}> \n
    \n \n \n \n \n {{faxMessage.status | uppercase}} \n
    \n
    \n \n
    \n \n
    \n
    \n
    \n
    \n
  • \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{ getCurrentUser().fullname }}\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n {{$select.selected.name}} - {{$select.selected.phone}}\n \n
\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n\n \n
\n
\n
\n
\n \n
\n
\n \n {{$item}}\n \n {{to}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n\n \n
\n
\n \n
\n
\n
\n \n\n \n
\n
\n \n \n \n \n \n \n \n \n \n
\n \n {{ item.file.name }}\n \n \n {{ item.file.size/1024/1024|number:2 }} MB\n \n \n
\n
\n
\n
\n \n \n
\n
\n
\n \n\n
\n
\n
\n
\n
\n
\n
\n\n'), -a.put("app/channels/fax/queue/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/fax/queue/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_QUEUES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/queue/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/fax/queue/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{queue.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/queue/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{$select.selected.toUpperCase()}}\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n'),a.put("app/channels/fax/realtime/view/agent/agent.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/fax/realtime/view/agent/agent.modal.info.html",'\n\n\n'),a.put("app/channels/fax/realtime/view/agent/queue.modal.add.html",'\n\n\n'),a.put("app/channels/fax/realtime/view/view.html",'\n\n\n'),a.put("app/channels/mail/account/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNTS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/account/view/action/list/list.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/mail/account/view/action/view/view.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACTION\' | translate }} \n
\n
\n
\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n
\n \n
\n \n \n {{$select.selected.fullname}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n \n
\n \n \n {{ $select.selected.name | translate }}\n \n {{ intType.name | translate }}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n
\n
\n \n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate}}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate }}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{ $select.selected.name}}\n \n {{ interval.name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n
\n
\n \n
\n
\n\n'), -a.put("app/channels/mail/account/view/action/wizard/wizard.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACTION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n
\n \n
\n \n \n {{$select.selected.fullname}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n\n \n
\n \n \n {{ $select.selected.name | translate }}\n \n {{ intType.name | translate }}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n
\n
\n \n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate}}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ weekDay.name | translate }}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n to\n \n {{ $select.selected.name | translate }}\n \n {{ month.name | translate }}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{ $select.selected.name}}\n \n {{ interval.name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n\n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/account/view/view.html",'\n
\n
\n \n\n\n\n\n \n
\n \n
\n \n
\n \n
\n \n\n \n
\n
\n {{ account.description || account.name }}\n
\n
\n {{account.email}}\n
\n
\n \n\n \n \n \n
\n
\n \n
\n \n
\n\n
\n'),a.put("app/channels/mail/account/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'), -a.put("app/channels/mail/account/wizard/wizard.html",'\n
\n
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/inbox/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_INBOX\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/inbox/mail/mail.html",'
\r\n
\r\n
\r\n From: \r\n {{mailMessage.from}}\r\n
\r\n To: \r\n {{mailMessage.to}} \r\n
\r\n Cc: \r\n {{mailMessage.cc}} \r\n
\r\n
\r\n {{\'APPLICATION_SENT_BY\' | translate}}: {{mailMessage.User.fullname}}\r\n
\r\n
\r\n
\r\n \r\n \r\n {{mailMessage.status | uppercase}}\r\n \r\n \r\n \r\n \r\n \r\n
\r\n \r\n
\r\n
\r\n {{mailAttachment.name}}\r\n \r\n {{mailAttachment.size}}B \r\n \r\n {{ \'APPLICATION_DOWNLOAD\' | translate }}\r\n \r\n
\r\n
\r\n'),a.put("app/channels/mail/inbox/note/note.html",'
\r\n
\r\n
\r\n \r\n
\r\n
\r\n {{\'APPLICATION_ADD_BY\' | translate}}: {{mailMessage.User.fullname}}\r\n
\r\n
\r\n
\r\n \r\n
\r\n
\r\n {{mailAttachment.name}}\r\n \r\n {{mailAttachment.size}}B \r\n \r\n {{ \'APPLICATION_DOWNLOAD\' | translate }}\r\n \r\n
\r\n
\r\n'),a.put("app/channels/mail/inbox/view/view.agents.modal.html",'\n\n\n'),a.put("app/channels/mail/inbox/view/view.html",'
\r\n
\r\n
\r\n \r\n
\r\n
\r\n
\r\n\r\n\r\n
\r\n
\r\n
\r\n
\r\n
\r\n\r\n'),a.put("app/channels/mail/inbox/view/view.notes.modal.html",'\n\n\n'),a.put("app/channels/mail/inbox/view/view.room.html",'\n
\n
\n
\n
\n \n {{mailRoom.status}} - {{mailRoom.subject}}\n
\n
\n
\n \n
\n
\n \n
\n
\n \n
\n
\n \n \n \n
\n
\n
\n
\n
\n
\n
\n
    \n
  • \n \n \n \n
  • \n
\n
\n
\n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
\n \n {{$select.selected.name}}\n \n
\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n {{$item}}\n \n {{to}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n {{$item}}\n \n {{cc}}\n \n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n
{{ item.file.name }}{{ item.file.size/1024/1024|number:2 }} MB\n
\n
\n
\n
\n \n \n \n \n \n
\n
\n
\n
\n
\n
\n \n \n
\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n\n'), -a.put("app/channels/mail/inbox/view/view.templates.modal.html",'\n\n\n'),a.put("app/channels/mail/queue/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/mail/queue/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_QUEUES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/queue/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_AVAILABLE_TEAMS\' | translate }}\n

\n
\n
\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/mail/queue/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{queue.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n \n'),a.put("app/channels/mail/queue/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$select.selected.toUpperCase()}}\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n'),a.put("app/channels/mail/realtime/view/agent/agent.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/realtime/view/agent/agent.modal.info.html",'\n\n\n'),a.put("app/channels/mail/realtime/view/agent/queue.modal.add.html",'\n\n\n'),a.put("app/channels/mail/realtime/view/queue/queue.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/realtime/view/session/session.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/mail/realtime/view/view.html",'\n\n\n'),a.put("app/channels/mail/realtime/view/view.queue.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/chanspy/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/voice/chanspy/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_CHANSPY\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/chanspy/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{chanspy.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/chanspy/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_CHANSPY\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item.value}}: {{$item.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'), -a.put("app/channels/voice/context/list/create.modal.html",'\n\n\n'),a.put("app/channels/voice/context/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_CONTEXTS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/context/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{context.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n \n'),a.put("app/channels/voice/context/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_CONTEXT\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_CANT_EDIT_NAME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/moh/list/create.modal.html",'\n\n\n'),a.put("app/channels/voice/moh/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_MOHS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/moh/view/view.addFiles.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_MOH\' | translate }} {{ \'APPLICATION_ADD_FILES\' | translate }} \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n
\n\n \n
\n \n \n {{$item.display_name}}\n \n {{sound.display_name}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/moh/view/view.audios.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_AUDIOS\' | translate}}\n
\n \n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_FOLDER_DOES_NOT_EXIST\' | translate }}\n

\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_PREVIEW\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{audiofile}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n {{ \'MESSAGE_NO_AUDIOFILES_AVAILABLE\' | translate }}\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/moh/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{moh.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/moh/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_MOH_CLASS\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n
\n \n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(sort.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/queue/list/list.create.modal.html",'\n\n\n'),a.put("app/channels/voice/queue/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_QUEUES\' | translate }}\n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/queue/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n

Warning!

{{ \'MESSAGE_NO_AVAILABLE_TEAMS\' | translate }}

\n
\n
\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/voice/queue/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{queue.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/queue/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_QUEUE_SETTINGS\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n
\n
\n \n
\n \n \n {{$select.selected.toUpperCase()}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_STRATEGY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_VOICE_MOH\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_TIMEOUT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_MAXLEN\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_RETRY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_WRAPUPTIME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_WEIGHT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_JOINEMPTY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_LEAVEWHENEMPTY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n
\n \n\n \n
\n
\n\n
\n
\n
\n
\n \n
\n \n \n {{$item.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{ \'DESCRIPTION_QUEUE_PERIODIC_ANNOUNCE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n
\n
\n

{{\'APPLICATION_SETTINGS\' | translate}}

\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE_FREQUENCY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_MIN_ANNOUNCE_FREQUENCY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_PERIODIC_ANNOUNCE_FREQUENCY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_RANDOM_PERIODIC_ANNOUNCE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE_HOLDTIME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE_POSITION\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_ANNOUNCE_POSITION_LIMIT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_REPORTHOLDTIME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n

{{\'APPLICATION_SOUNDS\' | translate}}

\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_REPORTHOLD\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_YOUARENEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_THEREARE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_CALLSWAITING\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_HOLDTIME\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_MINUTES\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_MINUTE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_SECONDS\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_THANKYOU\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n
\n \n \n
\n
\n\n
\n
\n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_AUTOPAUSE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_RINGINUSE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_QUEUE_MEMBER_DELAY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n {{ \'DESCRIPTION_ACW\' | translate }}\n \n \n {{\'APPLICATION_ACW\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_TIMEOUTRESTART\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_MONITOR_FORMAT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_QUEUE_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_ACW_TIMEOUT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'), -a.put("app/channels/voice/realtime/view/agent/agent.html",'\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/realtime/view/agent/agent.modal.info.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/agent/queue.modal.add.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/areport/report.html",'\n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_UNIQUEID\' | translate }}{{ \'APPLICATION_QUEUE\' | translate }}{{ \'APPLICATION_AGENT\' | translate }}{{ \'APPLICATION_CALLER\' | translate }}{{ \'APPLICATION_CALLED_AT\' | translate }}{{ \'APPLICATION_CONNECTED_AT\' | translate }}{{ \'APPLICATION_COMPLETED_AT\' | translate }}{{ \'APPLICATION_REASON\' | translate }}{{ \'APPLICATION_HOLDTIME\' | translate }}{{ \'APPLICATION_TALKTIME\' | translate }}
\n {{agent.uniqueid}}{{agent.queue}}{{agent.destcalleridname ? agent.destcalleridname + \' [\' + agent.membername + \']\' : agent.membername }}{{agent.calleridname ? agent.calleridname + \' [\' + agent.calleridnum + \']\' : agent.calleridnum }}\n \n \n \n \n \n \n {{agent.reason | uppercase}}\n {{agent.holdtime || 0 | VoiceRealtimeViewAgentReportFilter | date:\'HH:mm:ss\'}}{{agent.talktime || 0 | VoiceRealtimeViewAgentReportFilter | date:\'HH:mm:ss\'}}
\n No agents available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n
\n\n'),a.put("app/channels/voice/realtime/view/qreport/report.html",'\n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_UNIQUEID\' | translate }}{{ \'APPLICATION_QUEUE\' | translate }}{{ \'APPLICATION_AGENT\' | translate }}{{ \'APPLICATION_CALLER\' | translate }}{{ \'APPLICATION_CALLED_AT\' | translate }}{{ \'APPLICATION_CONNECTED_AT\' | translate }}{{ \'APPLICATION_ABANDONED_AT\' | translate }}
\n {{queue.uniqueid}}{{queue.queue}}{{queue.connectedlinename ? queue.connectedlinename + \' [\' + queue.connectedlinenum + \']\' : queue.connectedlinenum }}{{queue.calleridname ? queue.calleridname + \' [\' + queue.calleridnum + \']\' : queue.calleridnum }}\n \n \n \n \n \n
\n No queues available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n
\n\n'),a.put("app/channels/voice/realtime/view/queue/pause.modal.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/queue/queue.add.modal.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/queue/queue.html",'\n
\n
\n
Selection from a modal: {{ selected }}
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
{{ \'APPLICATION_QUEUE\' | translate }}{{ \'APPLICATION_AGENT\' | translate }}{{ \'APPLICATION_LAST_LOGIN\' | translate }}{{ \'APPLICATION_LAST_PAUSE\' | translate }}{{ \'APPLICATION_LAST_INCOMING_CALL\' | translate }}{{ \'APPLICATION_SERVED\' | translate }}
{{group.queue}}\n \n \n \n \n {{agent.membername}}\n \n \n \n \n \n {{agent.paused ? \'(\' + agent.reason + \')\' : \'\'}}\n \n \n \n {{agent.callstaken}}\n \n \n \n \n \n \n \n
\n \n \n \n \n {{agent.membername}}\n \n \n \n \n \n {{agent.paused ? \'(\' + agent.reason + \')\' : \'\'}}\n \n \n \n {{agent.callstaken}}\n \n \n \n
\n \n \n \n \n {{agent.membername}}\n \n \n \n \n \n {{agent.paused ? \'(\' + agent.reason + \')\' : \'\'}}\n \n \n \n {{agent.callstaken}}\n \n \n \n
\n No agents available\n
\n
\n \n \n
\n
\n \n
\n \n
\n\n
\n\n'),a.put("app/channels/voice/realtime/view/queue/queue.modal.add.html",'\n\n\n'), -a.put("app/channels/voice/realtime/view/queue/queue.modal.remove.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/queue/queue.remove.modal.html",'\n\n\n'),a.put("app/channels/voice/realtime/view/view.html",'\n\n\n'),a.put("app/channels/voice/recording/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_RECORDINGS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/inbound/list/create.modal.html",'\n\n\n\n'),a.put("app/channels/voice/route/inbound/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_INBOUND\' | translate }} {{ \'APPLICATION_ROUTES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/inbound/view/view.applications.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/inbound/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{route.exten}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n \n
\n
\n\n"),a.put("app/channels/voice/route/inbound/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_INBOUND\' | translate}} {{ \'APPLICATION_ROUTE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/internal/list/create.modal.html",'\n\n\n\n'),a.put("app/channels/voice/route/internal/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_INTERNAL\' | translate }} {{ \'APPLICATION_ROUTES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/internal/view/view.applications.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/internal/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{route.exten}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n \n
\n
\n\n"),a.put("app/channels/voice/route/internal/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_INTERNAL\' | translate}} {{ \'APPLICATION_ROUTE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/outbound/list/create.modal.html",'\n\n\n\n'), -a.put("app/channels/voice/route/outbound/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_OUTBOUND\' | translate }} {{ \'APPLICATION_ROUTES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/outbound/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{route.exten}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n \n
\n
\n\n"),a.put("app/channels/voice/route/outbound/view/view.route.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_NEW_ROUTE\' | translate }} WIZARD \n
\n
\n
\n
\n {{(main.app | capitalize) || \'Application\'}}\n
\n \n \n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_TRUNKS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_TRUNKS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n \n
\n \n \' placeholder=\'"name" \' class="form-control" data-ng-model="application.appdata[1]" data-ng-init="application.appdata[1] = null">\n \n {{ \'DESCRIPTION_OUTBOUND_CALLERID\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_OUTBOUND_PREFIX\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n
\n \n
\n \n \n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(intType.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(interval.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/route/outbound/view/view.routeSettings.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_APPLICATION_SETTINGS\' | translate }} WIZARD \n
\n
\n
\n \n
\n {{(main.app | capitalize) || \'Application\'}}\n
\n \n
\n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_TRUNKS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_TRUNKS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n \n \n\n \n
\n \n \' placeholder=\'"name" \' class="form-control" data-ng-model="route.Applications[selectedApp].appdata[1]">\n \n {{ \'DESCRIPTION_OUTBOUND_CALLERID\' | translate }} "name" <number>\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_OUTBOUND_PREFIX\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n
\n \n
\n \n \n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(intType.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(interval.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'), -a.put("app/channels/voice/route/outbound/view/view.routes.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACTIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/outbound/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_OUTBOUND\' | translate}} {{ \'APPLICATION_ROUTE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/route/view.application.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_NEW_APPLICATION\' | translate }} WIZARD \n
\n
\n
\n \n
\n {{(main.app | capitalize) || \'Application\'}}\n
\n \n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_QUEUES_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_QUEUES\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_PROJECTS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_PROJECTS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n {{$select.selected.mailbox}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_VOICEMAILS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_VOICEMAILS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n
\n \n
\n \n \n \n
\n \n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(interval.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n\n'), -a.put("app/channels/voice/route/view.applicationSettings.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_APPLICATION_SETTINGS\' | translate }} WIZARD \n
\n
\n
\n \n
\n {{(main.app | capitalize) || \'Application\'}}\n
\n \n
\n\n \n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_QUEUES_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_QUEUES\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$translate.instant($item.name)}}\n \n {{$translate.instant(queueOpt.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n \n \n {{$select.selected.display_name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_SOUNDS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_SOUNDS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(audioOpt.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_PROJECTS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_PROJECTS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n \n \n\n
\n
\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(hangupCause.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n {{$select.selected.mailbox}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_VOICEMAILS_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_VOICEMAILS\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n
\n \n
\n \n \n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(intType.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n
\n\n
\n\n \n
\n \n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(interval.name)}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'), -a.put("app/channels/voice/voicemail/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_VOICEMAILS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/voicemail/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{voicemail.mailbox}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/channels/voice/voicemail/view/view.messages.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_MESSAGES\' | translate}}\n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n'),a.put("app/channels/voice/voicemail/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_VOICEMAIL\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n \n \n \n\n
\n
\n
\n
\n
\n'),a.put("app/channels/voice/voicemail/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_VOICEMAIL\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n'),a.put("app/contactmanager/company/list/create.modal.html",'\n\n\n'),a.put("app/contactmanager/company/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_COMPANIES\' | translate }} \n
\n
\n \n
\n \n
\n \n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/contactmanager/company/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{company.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/contactmanager/company/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_COMPANY\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n
\n
\n
\n
\n'), -a.put("app/contactmanager/contact/list/import.modal.html",'\n\n\n'),a.put("app/contactmanager/contact/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_CONTACTS\' | translate }} \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_IMPORT_FROM_CSV\' | translate}}\n \n \n
\n \n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/contactmanager/service/list/create.modal.html",'\n\n\n'),a.put("app/contactmanager/service/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_SERVICES\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/contactmanager/service/view/create.modal.html",'\n\n\n'),a.put("app/contactmanager/service/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_AVAILABLE_TEAMS\' | translate }}\n

\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n'),a.put("app/contactmanager/service/view/view.customFieldSettings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_CUSTOM_FIELD\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n
\n\n
\n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n \n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n \n\n
\n\n \n
\n \n \n
\n \n \n
\n\n
\n
\n
\n
\n'),a.put("app/contactmanager/service/view/view.customFields.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CUSTOM_FIELDS\' | translate}}\n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/contactmanager/service/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{service.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'), -a.put("app/contactmanager/service/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_SERVICE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/dashboard/dashboard.html",'\n
\n
\n
\n \n
\n
\n
\n
\n\n'),a.put("app/dashboard/mail/mail.html",'
\nThis is the mail view.\n
\n'),a.put("app/dashboard/voice/voice.html",'
\n
\n
\n test\n
\n
\n
\n
\n \n {{ \'APPLICATION_INBOUND\' | translate }}\n \n\n
\n
\n
\n
\n \n
\n
\n
\n {{waiting || 0}}\n
\n
\n {{\'APPLICATION_WAITING\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{active || 0}}\n
\n
\n {{\'APPLICATION_ACTIVE\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{answered || 0}}\n
\n
\n {{\'APPLICATION_ANSWERED\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{abandoned || 0}}\n
\n
\n {{\'APPLICATION_ABANDONED\' | translate}}\n
\n
\n
\n
\n
\n\n
\n
\n
\n
\n \n
\n
\n
\n {{avganswertime || 0}}\n
\n
\n {{\'APPLICATION_AVG_ANSWER_TIME\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{avgtalktime || 0}}\n
\n
\n {{\'APPLICATION_AVG_TALK_TIME\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{answerrate || 0}}\n
\n
\n {{\'APPLICATION_ANSWER_RATE\' | translate}} (%)\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{abandonrate || 0}}\n
\n
\n {{\'APPLICATION_ABANDON_RATE\' | translate}} (%)\n
\n
\n
\n
\n
\n\n
\n
\n
\n
\n \n
\n
\n
\n {{totaloffered || 0}}\n
\n
\n {{\'APPLICATION_TOTAL_OFFERED\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{unmanaged || 0}}\n
\n
\n {{\'APPLICATION_UNMANAGED\' | translate}}\n
\n
\n
\n
\n
\n
\n\n
\n \n {{ \'APPLICATION_OUTBOUND\' | translate }}\n \n\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutbound || 0}}\n
\n
\n {{\'APPLICATION_MANUAL_OUTBOUND\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutboundglobalduration || 0}}\n
\n
\n {{\'APPLICATION_GLOBAL_DURATION\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutboundanswered || 0}}\n
\n
\n {{\'APPLICATION_ANSWERED\' | translate}}\n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutboundavgduration || 0}}\n
\n
\n {{\'APPLICATION_AVG_DURATION\' | translate}} (%)\n
\n
\n
\n
\n
\n\n
\n
\n
\n
\n \n
\n
\n
\n {{manualoutboundanswerrate || 0}}\n
\n
\n {{\'APPLICATION_ANSWER_RATE\' | translate}} (%)\n
\n
\n
\n
\n
\n\n
\n
\n
\n'),a.put("app/desk/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_DESK_COM\' | translate }} \n
\n \n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_EMAIL\' | translate }}{{ \'APPLICATION_REMOTE_ADDRESS\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{account.name}}{{account.username}}{{account.remoteUri}}{{account.description}}\n \n {{ \'APPLICATION_EDIT\' | translate }}\n \n \n {{ \'APPLICATION_CHECK_CONNECTION\' | translate }}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No account available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/desk/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/desk/view/view.configuration.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_CONFIGURATION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/desk/view/view.configurationSettings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n \n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n
\n
\n
\n
\n
\n'), -a.put("app/desk/view/view.configurations.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_DESCRIPTION\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{configuration.name}}{{configuration.description}}\n \n {{ \'APPLICATION_SETTINGS\' | translate}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No configuration available\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/desk/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/desk/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_DOMAIN\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/freshdesk/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_FRESHDESK\' | translate }} \n
\n \n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_EMAIL\' | translate }}{{ \'APPLICATION_REMOTE_ADDRESS\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{account.name}}{{account.username}}{{account.remoteUri}}{{account.description}}\n \n {{ \'APPLICATION_EDIT\' | translate }}\n \n \n {{ \'APPLICATION_CHECK_CONNECTION\' | translate }}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No account available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/freshdesk/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/freshdesk/view/view.configuration.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_CONFIGURATION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/freshdesk/view/view.configurationSettings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n \n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected[0]}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n
\n
\n
\n
\n
\n'), -a.put("app/freshdesk/view/view.configurations.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_DESCRIPTION\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{configuration.name}}{{configuration.description}}\n \n {{ \'APPLICATION_SETTINGS\' | translate}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No configuration available\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/freshdesk/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/freshdesk/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_DOMAIN\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/integration/list/list.html",'\n\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_INTEGRATIONS\' | translate }} \n
\n
\n \n New App \n \n \n \n \n \n
\n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_ID\' | translate }}{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_FILENAME\' | translate }}{{ \'APPLICATION_VERSION\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{integration.id}}{{integration.name}}{{integration.filename}}{{integration.version}}{{integration.description}}\n \n {{ \'APPLICATION_UPDATE\' | translate }} \n \n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No integrations available\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n \n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/jscripty/project/list/list.create.modal.html",'\n\n\n'),a.put("app/jscripty/project/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_PROJECTS\' | translate }} \n
\n \n
\n
\n \n\n \n\n\n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/jscripty/project/report/report.detail.html",'
\n
\n \n
\n\n
\n
\n
\n
\n
\n Questions Detail\n
\n \n
\n
\n
\n
\n
\n {{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}\n\n
\n
\n
\n

\n Question Id: {{id}}\n

\n\n
\n
\n
\n
\n
\n

\n {{label}}\n

\n\n
\n
\n
\n
\n

\n \n\n

\n {{question}}\n
\n
\n
\n \n \n \n \n \n \n \n \n \n\n \n \n\n \n\n \n
Answer Count
{{answer.question_answer || \'No answer\'}}{{answer.count}}
\n
\n
\n\n
\n
\n
\n\n\n
\n\n\n
\n
\n \n
\n\n
\n\n
\n
\n\n
\n\n
\n\n
\n
\n
\n'),a.put("app/jscripty/project/report/report.html",'\n
\n
\n\n \n
\n
\n \n
\n \n
\n \n \n
\n
\n
\n
\n\n
\n
\n \n\n \n \n \n\n
\n\n
\n\n
\n
\n
\n
\n
\n
\n
\n

{{projectStats.started}}

\n Started\n
\n
\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n

{{projectStats.incomplete}}

\n Incomplete\n
\n
\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n

{{projectStats.completed}}

\n Completed\n
\n
\n \n
\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n\n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/jscripty/project/report/report.session.detail.html",'\n\n
\n
\n
\n
\n
\n Session Detail\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n

\n

\n Session Id: {{sessionQuestions.session_id}}

\n

\n

\n

\n Status: {{sessionQuestions.status}}

\n

\n

\n

\n Started At: {{sessionQuestions.createdAt}}

\n

\n

\n

\n Closed At: {{sessionQuestions.completedAt}}

\n

\n
\n\n
\n\n
\n
\n

\n \n {{question.question_label}} [ID : {{question.question_id}}]

\n\n
\n
\n\n
\n
\n

Question:

{{question.question_text}}\n
\n
\n
\n
\n

Answer:

{{question.question_answer}}\n
\n
\n
\n

\n \n {{question.question_other_label}}: \n

\n {{question.question_other_answer}}\n
\n
\n\n\n
\n
\n \n \n \n \n \n \n \n \n\n \n\n \n \n\n \n\n \n
Label Answer
{{input.input_label}}{{input.input_value || \'No Answer\'}}
\n\n
\n
\n
\n
\n
\n\n
\n\n
\n\n
\n
\n
\n'), -a.put("app/jscripty/project/report/report.sessions.html",'\n\n
\n
\n \n
\n
\n
\n Project Sessions\n
\n
\n \n \n
\n
\n
\n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n\n
\n
\n
\n \n
\n
\n\n'),a.put("app/jscripty/project/report/report.summary.html",'
\n
\n
\n
\n
\n
\n Questions Summary\n\n
\n
\n \n \n
\n
\n
\n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n\n
\n\n
\n\n
\n
\n
\n
\n'),a.put("app/jscripty/project/view/view.html",'\n\n
\n
\n
\n
\n
\n\n\n'),a.put("app/login/login.html",'\n\n\n\n
\n \n \n
\n\n\n'),a.put("app/main/chooseContact.modal.html",'\n\n\n'),a.put("app/main/closeEditedTab.modal.html",'\n\n\n'),a.put("app/main/main.html",'\n\n\n\n
\n
\n\n
\n\n \n
\n
\n \n\n \n
\n
\n\n \n \n \n \n Motion \n \n
\n
\n \n \n {{workspace.name}} \n \n
\n \n \n \n
\n
\n
\n \n\n
\n
\n \n\n \n \n
\n
\n \n\n
\n\n\n\n\n\n\n\n\n\n\n\n'),a.put("app/main/template/actionBuilder/template.actionBuilderIntegration.html",'
\n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n \n'+" {{'APPLICATION_WARNING' | translate}}! {{'MESSAGE_REQUIRED_FIELD' | translate}}.\n \n
\n"),a.put("app/main/template/actionBuilder/template.actionBuilderStatus.html",'
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n'+" {{'APPLICATION_WARNING' | translate}}! {{'MESSAGE_REQUIRED_FIELD' | translate}}.\n \n
\n"),a.put("app/main/template/actionBuilder/template.actionBuilderTemplate.html",'
\n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n
\n'),a.put("app/main/template/template.conditionBuilder.html",'
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n'+" {{'APPLICATION_WARNING' | translate}}! {{'MESSAGE_REQUIRED_FIELD' | translate}}.\n \n
\n"),a.put("app/main/template/template.contactTab.html",'
\n
\n
\n \n
\n \n
\n
\n \n
\n
\n
\n \n
\n

{{\'MESSAGE_INBOUND_CALL_FROM\' | translate}} - {{data.calleridnum}}

\n

\n {{\'MESSAGE_CALL_UNIQUEID\' | translate}} : {{data.uniqueid}}\n

\n
\n
\n
\n
\n
\n {{\'APPLICATION_QUEUE\' | translate}} \n {{workspace.data.queue}} \n
\n
\n
\n
\n {{\'APPLICATION_AGENT\' | translate}} \n {{workspace.data.membername}} \n
\n
\n
\n
\n {{\'APPLICATION_DATE\' | translate}} \n {{workspace.data.agentcalledAt}} \n
\n
\n
\n \n \n
\n
\n
\n \n {{\'APPLICATION_DETAIL\' | translate}}\n
\n
\n
\n \n \n
\n
\n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n

Warning!

\n

\n {{ \'MESSAGE_NO_COMPANIES_AVAILABLE\' | translate }}\n

\n

\n {{\'APPLICATION_GO_TO\' | translate}} {{\'APPLICATION_COMPANIES\' | translate}}\n

\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n {{$item}}\n \n {{tag}}\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n
\n
\n \n
\n \n \n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n \n {{\'APPLICATION_CUSTOM_FIELDS\' | translate}}\n
\n
\n
\n
\n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n {{$select.selected.value}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n
\n
\n \n
\n
\n \n
\n
\n
\n \n {{\'APPLICATION_LOG\' | translate}}\n
\n \n
\n
\n \n
\n
\n
\n
\n
\n \n \n
|\n
\n \n \n
|\n
\n \n \n
\n
\n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n
\n
\n
\n
\n
\n
\n \n \n
|\n
\n \n \n
|\n
\n \n \n
\n
\n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n
\n
\n
\n \n
\n
\n \n
\n \n \n
\n
\n
\n'), -a.put("app/main/template/template.jscriptyTab.html",'
\n\n \n
\n
\n \n
\n \n \n
\n \n
\n \n \n
\n \n
\n
\n
\n\n
\n \n {{attribute.value}} \n\n
\n\n\n
\n
\n
\n
\n
\n
\n\n \n
\n

{{attribute.value}}

\n
\n \n\n
\n
\n \n
\n
\n\n\n \n\n
\n
\n \n
\n
\n \n
\n\n
\n \n\n
\n
\n
\n
\n
\n \n\n
\n\n
\n \n \n \n \n\n
\n\n
\n
\n
\n\n
\n\n
\n \n
\n
\n \n\n
\n
\n \n \n\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n
\n'),a.put("app/main/template/template.reportBuilderView.html",'
\n
\n \n \n \n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.field | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n
\n
\n
\n
\n'),a.put("app/market/market.html",'
\n
\n \n
\n
\n\n
\n
\n \n
\n

Our Integrations

\n
\n
\n
\n
\n

{{integration.name}} {{integration.author}}

\n {{integration.name}}\n
\n

\n {{integration.description}}\n

\n \n
\n
\n
\n {{status}}\n
\n
\n
\n
\n
\n \n \n
\n
\n'),a.put("app/motionbar/motionbar.chat.html",'
\n'),a.put("app/salesforce/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_SALESFORCE\' | translate }} \n
\n \n
\n
\n \n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n \n \n \n \n
\n
\n
\n
{{ \'APPLICATION_NAME\' | translate }}{{ \'APPLICATION_EMAIL\' | translate }}{{ \'APPLICATION_REMOTE_ADDRESS\' | translate }}{{ \'APPLICATION_DESCRIPTION\' | translate }}{{ \'APPLICATION_ACTIONS\' | translate }}
{{account.name}}{{account.username}}{{account.remoteUri}}{{account.description}}\n \n {{ \'APPLICATION_EDIT\' | translate }}\n \n \n {{ \'APPLICATION_CHECK_CONNECTION\' | translate }}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No account available\n
\n \n
\n \n \n
\n
\n
\n \n \n
\n
\n
\n \n \n
\n
\n \n
\n \n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/salesforce/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/salesforce/view/view.configuration.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_CONFIGURATION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/salesforce/view/view.configurationSettings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n \n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n
\n
\n
\n
\n
\n'), -a.put("app/salesforce/view/view.configurations.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_DESCRIPTION\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{configuration.name}}{{configuration.description}}\n \n {{ \'APPLICATION_SETTINGS\' | translate}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No configuration available\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/salesforce/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/salesforce/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/setting/license/view/view.html",'\n\n
\n \n\n \n
\n
\n
\n
\n
\n

{{\'APPLICATION_MONTH_TO_MONTH\' | translate}}{{license.token || \'unknown\'}}

\n

{{\'APPLICATION_YEARLY\' | translate}}{{license.token || \'unknown\'}}

\n

{{\'APPLICATION_PERPETUAL\' | translate}}{{license.token || \'unknown\'}}

\n

{{\'APPLICATION_UNKNOWN\' | translate}}{{license.token || \'unknown\'}}

\n

{{license.expiration ? (license.expiration | date:\'medium\') : \'DEMO\'}}\n Expiration Date \n

\n
\n
    \n
  • \n
    \n {{\'APPLICATION_USERS\' | translate}}:\n
    \n
    \n {{(license.users || license.users >= 0) ? license.users : \'unknown\'}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_AGENTS\' | translate}} ({{\'APPLICATION_CONCURRENTS\' | translate}}):\n
    \n
    \n {{(license.agents || license.agents >= 0) ? license.agents : \'unknown\'}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_TELEPHONES\' | translate}}:\n
    \n
    \n {{(license.telephones || license.telephones >= 0) ? license.telephones : \'unknown\'}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_CHAT\' | translate}}:\n
    \n
    \n {{license.chat ? \'APPLICATION_ENABLED\' : \'APPLICATION_DISABLED\' | translate}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_MAIL\' | translate}}:\n
    \n
    \n {{license.mail ? \'APPLICATION_ENABLED\' : \'APPLICATION_DISABLED\' | translate}}\n
    \n
  • \n
  • \n
    \n {{\'APPLICATION_FAX\' | translate}}:\n
    \n
    \n {{license.fax ? \'APPLICATION_ENABLED\' : \'APPLICATION_DISABLED\' | translate}}\n
    \n
  • \n
\n \n
\n
\n
\n
\n
\n
\n \n FORM {{ \'APPLICATION_LICENSE\' | translate }} \n
\n
\n
\n
\n\n \n
\n \n
\n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/setting/smtp/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_NUMERIC_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n \n
\n \n
\n \n
\n
\n\n'),a.put("app/setting/update/list/landing.html",'\n
\n
\n \n \n
\n
\n
\n {{countdown}}\n
\n
\n

Wait! We need to restart xCALLY Motion server.

\n

\n We are updatig it!
\n xCALLY Motion Team

\n

\n
\n
\n
\n \n
\n
\n\n'),a.put("app/setting/update/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_UPDATES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n \n
\n
\n
\n\n'),a.put("app/setting/update/list/list.pull.html",'\n\n\n'),a.put("app/square/odbc/list/list.create.modal.html",'\n\n\n'), -a.put("app/square/odbc/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_ODBCS\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/square/odbc/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{odbc.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/square/odbc/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ODBC\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n

Es. DRIVER=MySQL;SERVER=127.0.0.1;UID=xcall;PWD=password;DATABASE=motion

\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/square/project/list/list.create.modal.html",'\n\n\n'),a.put("app/square/project/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_PROJECTS\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/square/project/view/view.html",'\n\n
\n
\n
\n
\n
\n\n\n'),a.put("app/staff/agent/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_AGENTS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/agent/view/view.account.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_FORMAT\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n \n \n\n \n
\n
\n \n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{ \'APPLICATION_SELECT_IMAGE\' | translate }} \n
\n
\n \n \n
\n

\n
{{ \'MESSAGE_SUPPORTED_FORMATS\' | translate }} jpg, png, jpeg.\n

\n
\n
\n
\n
\n
\n \n \n \n \n \n \n \n \n
\n \n {{ item.file.name }}\n \n \n {{ item.file.size/1024/1024|number:2 }} MB\n \n \n
\n
\n
\n
\n \n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/view/view.chat.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_CHAT\' | translate}}\n
\n
\n\n
\n \n
\n \n
\n \n \n \n {{\'MESSAGE_ZERO_MEANS_UNLIMITED\' | translate}}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/view/view.fax.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_FAX\' | translate}}\n
\n
\n\n
\n \n
\n \n
\n \n \n \n {{\'MESSAGE_ZERO_MEANS_UNLIMITED\' | translate}}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/view/view.html",'\n
\n \n
\n\n'),a.put("app/staff/agent/view/view.mail.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_MAIL\' | translate}}\n
\n
\n\n
\n \n
\n \n
\n \n \n \n {{\'MESSAGE_ZERO_MEANS_UNLIMITED\' | translate}}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n
\n
\n
\n
\n
\n'), -a.put("app/staff/agent/view/view.phonebar.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_PHONE_BAR\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n \n
\n
\n \n
\n \n \n
\n \n\n \n
\n \n \n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/view/view.voice.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_VOICE\' | translate}}\n
\n
\n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{transport}}\n \n \n \n {{ \'DESCRIPTION_VOICE_TRANSPORT\' | translate }}\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_VOICE_HOST\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{nat}}\n \n \n \n {{ \'DESCRIPTION_VOICE_NAT\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_VOICE_TYPE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{allow}}\n \n \n \n {{ \'DESCRIPTION_VOICE_CODEC\' | translate }}\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/agent/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_AGENT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INVALID_PATTERN_NAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_FORMAT\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n
\n\n \n
\n \n \n {{$item}}\n \n {{transport}}\n \n \n \n {{ \'DESCRIPTION_VOICE_TRANSPORT\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{allow}}\n \n \n \n {{ \'DESCRIPTION_VOICE_CODEC\' | translate }}\n \n
\n \n\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n'),a.put("app/staff/team/list/create.modal.html",'\n\n\n'),a.put("app/staff/team/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TEAMS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/team/view/view.agents.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_AGENTS\' | translate}}\n
\n
\n
\n \n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n \n \n
\n
\n
\n
\n'),a.put("app/staff/team/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{team.name}}\n
\n\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n \n
\n
\n\n'),a.put("app/staff/team/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_ACCOUNT\' | translate}}\n
\n
\n\n
\n \n
\n\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n'),a.put("app/staff/telephone/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TELEPHONES\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'), -a.put("app/staff/telephone/view/view.account.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_INTERNAL\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n\n \n
\n \n \n {{$item}}\n \n {{transport}}\n \n \n \n {{ \'DESCRIPTION_VOICE_TRANSPORT\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{allow}}\n \n \n \n {{ \'DESCRIPTION_VOICE_CODEC\' | translate }}\n \n
\n \n\n \n
\n
\n \n\n \n
\n
\n \n \n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/staff/telephone/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{item.fullname}}\n
\n
\n {{item.role}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/telephone/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TELEPHONE\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INVALID_PATTERN_NAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n \n \n \n \n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_INTERNAL\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n
\n\n \n
\n \n \n {{$item}}\n \n {{transport}}\n \n \n \n {{ \'DESCRIPTION_VOICE_TRANSPORT\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n {{allow}}\n \n \n \n {{ \'DESCRIPTION_VOICE_CODEC\' | translate }}\n \n
\n \n\n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n'),a.put("app/staff/user/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_USERS\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/user/view/view.account.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PROFILE\' | translate}} {{ \'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_FORMAT\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n \n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{ \'APPLICATION_SELECT_IMAGE\' | translate }} \n
\n
\n \n \n
\n

\n
{{ \'MESSAGE_SUPPORTED_FORMATS\' | translate }} jpg, png, jpeg.\n

\n
\n
\n
\n
\n
\n \n \n \n \n \n \n \n \n
\n \n {{ item.file.name }}\n \n \n {{ item.file.size/1024/1024|number:2 }} MB\n \n \n
\n
\n
\n
\n \n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'), -a.put("app/staff/user/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{user.fullname}}\n
\n
\n {{user.role}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/staff/user/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_USER\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INVALID_PATTERN_NAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_FORMAT\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n'),a.put("app/sugarcrm/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_SUGARCRM\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/sugarcrm/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/sugarcrm/view/view.configuration.html",'
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_CONFIGURATION\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/sugarcrm/view/view.configurationSettings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n \n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.label}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected | ucfirst}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n
\n
\n
\n
\n
\n'),a.put("app/sugarcrm/view/view.configurations.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_DESCRIPTION\' | translate}}{{ \'APPLICATION_ACTIONS\' | translate }}
{{configuration.name}}{{configuration.description}}\n \n {{ \'APPLICATION_SETTINGS\' | translate}}\n \n \n {{ \'APPLICATION_DELETE\' | translate }}\n \n
\n No configuration available\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/sugarcrm/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'), -a.put("app/sugarcrm/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_DOMAIN\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'),a.put("app/tools/answer/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/answer/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_CANNED_ANSWERS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/answer/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{answer.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/answer/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_CANNED_ANSWER\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/automation/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_AUTOMATIONS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/automation/view/view.html",'\n
\n
\n \n\n\n\n\n \n
\n \n
\n \n
\n \n
\n \n\n \n
\n
\n {{ automation.name }}\n
\n
\n {{ automation.description }}\n
\n
\n \n\n \n \n \n
\n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/automation/view/view.settings.html",'
\n
\n
\n \n
\n \n
\n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ACTIONS\' | translate }}:\n
\n
\n
\n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n \n
\n \n
\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_CONDITION\' | translate}}.\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_ACTION\' | translate}}.\n \n
\n \n
\n
\n
\n
\n
\n
\n
\n'),a.put("app/tools/automation/wizard/wizard.html",'
\n
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_AUTOMATIONS\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n \n {{ \'APPLICATION_CHANNEL\' | translate }}\n
\n
\n
\n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ACTIONS\' | translate }}:\n
\n
\n
\n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n \n
\n \n
\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_CONDITION\' | translate}}.\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_ACTION\' | translate}}.\n \n
\n \n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'), -a.put("app/tools/interval/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/interval/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_INTERVALS\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/interval/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{interval.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n"),a.put("app/tools/interval/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_INTERVAL\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/interval/view/view.subinterval.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_NEW_SUBINTERVAL\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n\n\n\n \n
\n
\n\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/tools/interval/view/view.subintervalSettings.html",'\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_SUBINTERVAL_SETTINGS\' | translate }} WIZARD \n
\n
\n
\n \n
\n {{subinterval.name}}\n
\n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n
\n
\n
to
\n
\n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(weekDay.name)}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n to\n \n {{$select.selected}}\n \n {{monthDay}}\n \n \n
\n
\n \n\n \n
\n \n
\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n to\n \n {{$translate.instant($select.selected.name)}}\n \n {{$translate.instant(month.name)}}\n \n \n
\n
\n \n\n\n\n \n
\n
\n\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/tools/interval/view/view.subintervals.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_SUBINTERVALS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/tools/pause/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/pause/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_PAUSES\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/pause/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{pause.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/pause/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_PAUSE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/sound/list/list.html",'\n\n\n\n
\n

{{ \'APPLICATION_SOUNDS\' | translate }}

\n
\n
\n
\n
\n \n \n {{\'APPLICATION_FILE_UPLOAD\' | translate}} \n
\n
\n \n \n
\n
\n
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_SELECT_FILES\' | translate}}\n \n
\n
\n
\n
\n
\n
\n
\n Base drop zone\n
\n
\n \n \n {{\'APPLICATION_FILE_UPLOAD\' | translate}}\n \n \n \n \n {{\'APPLICATION_MULTI_FILE_UPLOAD\' | translate}}\n
\n
\n

\n
\n {{ \'MESSAGE_SUPPORTED_FORMATS\' | translate }} wav, mp3, gsm, ogg.\n

\n

\n {{ \'MESSAGE_MAXIMUM_SOUND_UPLOAD_SIZE\' | translate }} 15 Mb.\n

\n
\n
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_UPLOAD_QUEUE\' | translate}}\n {{\'APPLICATION_QUEUE_LENGTH\' | translate}}: {{ uploader.queue.length }}\n
\n
\n
\n
\n
\n
\n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n \n
{{\'APPLICATION_NAME\' | translate}}{{\'APPLICATION_SIZE\' | translate}}{{\'APPLICATION_PROGRESS\' | translate}}{{\'APPLICATION_STATUS\' | translate}}{{\'APPLICATION_MESSAGE\' | translate}}{{\'APPLICATION_ACTIONS\' | translate}}
{{ item.file.name }}{{ item.file.size/1024/1024|number:2 }} MB\n
\n
\n
\n
\n \n \n \n \n \n {{item.responseMessage}}\n \n \n \n \n
\n
\n
\n

{{\'APPLICATION_UPLOAD_QUEUE_PROGRESS\' | translate}}:

\n
\n
\n
\n
\n \n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n

{{ \'MESSAGE_NO_SOUNDS\' | translate }}

\n

\n \n {{ \'MESSAGE_RETURN_HOME\' | translate }} \n {{ \'MESSAGE_OR_UPLOAD_SOUND_FILE\' | translate }}\n

\n
\n
\n
\n
\n
\n \n \n
\n
\n \n
\n

\n {{ sound.description || "Empty" }}\n

\n

\n \n \n \n

\n
\n
\n
\n \n
\n\n'), -a.put("app/tools/tag/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/tag/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TAGS\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/tag/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{tag.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/tag/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_TAG\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/template/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_TEMPLATES\' | translate }}\n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/template/view/view.html",'\n
\n
\n \n\n \n
\n\n \n
\n \n
\n \n
\n \n \n
\n
\n {{item.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/template/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_SETTINGS\' | translate}}\n
\n
\n
\n\n
\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n
\n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n\n
\n
\n
\n
\n {{\'APPLICATION_VARIABLES\' | translate}}\n
\n
\n
\n \n \n {{group.content | translate}}\n
    \n
  1. \n {{variable}}\n
  2. \n
\n
\n
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n\n \n
\n
\n
\n
\n
\n'),a.put("app/tools/template/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TEMPLATES\' | translate }} FORM \n
\n
\n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n \n
\n
\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n \n\n \n
\n
\n
\n
\n
\n {{\'APPLICATION_VARIABLES\' | translate}}\n
\n
\n
\n \n \n {{group.content | translate}}\n
    \n
  1. \n {{variable}}\n
  2. \n
\n
\n
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n\n
\n \n
\n
\n
\n \n
\n'),a.put("app/tools/trigger/list/list.html",'\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_TRIGGERS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/trigger/view/view.html",'\n
\n
\n \n\n\n\n\n \n
\n \n
\n \n
\n \n
\n \n\n \n
\n
\n {{ trigger.name }}\n
\n
\n {{ trigger.description }}\n
\n
\n \n\n \n \n \n
\n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/trigger/view/view.settings.html",'
\n
\n
\n \n
\n \n
\n
\n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ACTIONS\' | translate }}:\n
\n
\n
\n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n
\n \n
\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_CONDITION\' | translate}}.\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_ACTION\' | translate}}.\n \n
\n \n
\n
\n
\n
\n
\n
\n
\n'), -a.put("app/tools/trigger/wizard/wizard.html",'
\n
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TRIGGERS\' | translate }} WIZARD\n
\n
\n
\n \n \n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n \n
\n
\n
\n
\n \n {{ \'APPLICATION_CHANNEL\' | translate }}\n
\n
\n
\n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n :\n
\n
\n
\n
\n \n \n
\n \n
\n
\n
\n
\n
\n \n {{ \'APPLICATION_ACTIONS\' | translate }}:\n
\n
\n
\n
\n
\n \n {{$select.selected.name | translate}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n
\n \n \n
\n \n
\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_CONDITION\' | translate}}.\n \n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_INSERT_AT_LEAST_ONE_ACTION\' | translate}}.\n \n
\n \n \n
\n
\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n
\n\n'),a.put("app/tools/trunk/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TRUNKS\' | translate }} \n
\n \n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/trunk/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{trunk.name}}\n
\n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/trunk/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_TRUNK\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_HOST\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_SECRET\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected.name}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_VOICE_CONTEXT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \' placeholder="{{\'APPLICATION_CALLERID\' | translate}}" class="form-control" data-ng-model="trunk.callerid"/>\n \n {{ \'DESCRIPTION_OUTBOUND_CALLERID\' | translate }} "name" <number>\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_TYPE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_DTMFMODE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_DEFAULT_USER\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_NAT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_QUALIFY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_ALLOW_CODEC\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_INSECURE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_CALLLIMIT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n \n \n
\n \n\n \n
\n
\n \n \n
\n
\n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_REGISTRY\' | translate }}\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_DIRECTMEDIA\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_CALLCOUNTER\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_FROMDOMAIN\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_FROMUSER\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_OUTBOUNDPROXY\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_USEREQPHONE\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_TRUSTRPID\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_SENDRPID\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_ENCRYPTION\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_PORT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$item}}\n \n
\n
\n
\n \n {{ \'DESCRIPTION_TRUNK_TRANSPORT\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n
\n
\n\n \n
\n
\n \n \n
\n
\n
\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_OTHER_FIELDS\' | translate }}\n \n
\n \n
\n
\n
\n \n
\n
host=dynamicp
\n
secret=********
\n
regcontext=tammari-internal
\n
regexten=1005
\n
dtmfmode=rfc2833
\n
insecure=invite,port
\n
canreinvite=yes
\n
nat=yes
\n
qualify=yes
\n
context=merus-sipphone
\n
pickupgroup=1
\n
callgroup=1
\n
mailbox=1000@default
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n
\n'), -a.put("app/tools/trunk/wizard/wizard.html",'
\n \n \n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_TRUNK\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_HOST\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_SECRET\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_DEFAULT_USER\' | translate }}\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_WRONG_PASSWORD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n
\n\n \n
\n\n \n
\n \n \n \n {{ \'DESCRIPTION_TRUNK_REGISTRY\' | translate }}\n \n
\n \n \n \n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n \n
\n
\n
\n
\n \n
\n'),a.put("app/tools/variable/list/list.create.modal.html",'\n\n\n'),a.put("app/tools/variable/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_VARIABLES\' | translate }} \n
\n
\n \n
\n \n
\n
\n
\n
\n \n
\n
{{ \'MESSAGE_NO_RESULTS_AVAILABLE\' | translate }}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/variable/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{variable.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/variable/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_VARIABLE\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/tools/yourdashboard/list/clone.modal.html",'\n\n\n'),a.put("app/tools/yourdashboard/list/create.modal.html",'\n\n\n'),a.put("app/tools/yourdashboard/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_YOUR_DASHBOARDS\' | translate }} \n
\n
\n \n
\n \n
\n \n
\n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/yourdashboard/show/show.html",'
\n
\n \n
\n
\n'),a.put("app/tools/yourdashboard/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{dashboard.name}}\n
\n \n
\n \n\n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/tools/yourdashboard/view/view.settings.html",'
\n
\n
\n
\n
\n \n {{ \'APPLICATION_DASHBOARD\' | translate}} {{ \'APPLICATION_SETTINGS\' | translate}} \n
\n \n
\n\n
\n
\n \n
\n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n
\n \n
\n \n\n \n
\n \n \n
\n \n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/zendesk/list/list.html",'\n
\n
\n \n\n \n
\n
\n
\n \n {{ \'APPLICATION_ZENDESK\' | translate }} \n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n \n
\n
\n \n
\n
\n\n'),a.put("app/zendesk/view/configuration/list/create.modal.html",'\n\n\n'),a.put("app/zendesk/view/configuration/list/list.html",'
\n
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATIONS\' | translate}}\n
\n \n
\n
\n \n
\n
{{\'MESSAGE_NO_RESULTS_AVAILABLE\' | translate}}
\n
\n
\n
\n
\n
\n
\n'), -a.put("app/zendesk/view/configuration/view/view.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_CONFIGURATION\' | translate}}: {{configurationName}}\n
\n \n
\n
\n
\n \n
\n
\n
\n All following fields will be join by blank space:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n All following fields will be join by new line:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n \n
\n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Add how to fill the fields present in your account:\n
\n
\n \n
\n
\n
\n \n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n
\n \n {{$select.selected.title}}\n \n
\n
\n
\n
\n
\n
\n
\n \n {{$select.selected.name}}\n \n
\n
\n
\n
\n
\n
\n
\n \n
\n
\n
\n \n
\n \n \n
\n
\n
\n Select tags that you want add in the ticket:\n
\n
\n
\n
\n \n
\n \n {{$item.name}}\n \n {{tag.name}}\n \n \n
\n \n \n
\n
\n \n
\n
\n
\n
\n
\n'),a.put("app/zendesk/view/view.account.html",'
\n
\n
\n
\n
\n \n {{\'APPLICATION_ACCOUNT\' | translate}}\n
\n \n
\n
\n
\n \n
\n
\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n
\n \n\n
\n
\n
\n
\n
\n'),a.put("app/zendesk/view/view.html",'\n
\n
\n \n\n \n
\n \n
\n \n
\n \n
\n \n \n
\n
\n {{account.name}}\n
\n
\n {{account.remoteUri}}\n
\n
\n \n \n \n \n
\n \n
\n \n \n
\n
\n \n
\n
\n\n'),a.put("app/zendesk/wizard/wizard.html",'\n\n\n\n\n
\n
\n \n
\n
\n
\n \n {{ \'APPLICATION_ACCOUNT\' | translate }} WIZARD \n
\n
\n
\n \n \n
\n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_USERNAME\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_EXIST_DOMAIN\' | translate}}.\n \n
\n \n\n \n
\n \n \n {{$select.selected | capitalize}}\n \n
\n
\n
\n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n
\n \n \n \n {{\'APPLICATION_WARNING\' | translate}}! {{\'MESSAGE_REQUIRED_FIELD\' | translate}}.\n \n
\n \n\n \n\n
\n
\n\n \n

{{\'MESSAGE_CONFIGURATION_COMPLETED\' | translate}}

\n \n
\n\n
\n\n
\n
\n \n
\n
\n\n'), -a.put("components/footer/footer.html",'\n\n\n'),a.put("components/header/header.html",'\n\n\n'),a.put("components/modal/delete.html",'\n\n\n'),a.put("components/quickSidebar/modal/add.html",'\n\n\n\n\n'),a.put("components/quickSidebar/modal/close.html",'\n\n\n'),a.put("components/quickSidebar/quickSidebar.html",'
\n \n
\n'),a.put("components/sidebar/sidebar.html",'\n'); -}]); \ No newline at end of file diff --git a/public/index.html b/public/index.html index d6d07e4..f59a794 100644 --- a/public/index.html +++ b/public/index.html @@ -61,7 +61,7 @@ - + diff --git a/release-notes/changelog_0.0.70.txt b/release-notes/changelog_0.0.70.txt index b257b8a..a22a9ca 100644 --- a/release-notes/changelog_0.0.70.txt +++ b/release-notes/changelog_0.0.70.txt @@ -1,5 +1,8 @@ # xCALLY MOTION Changelog +- * 3f4d3c3 - 2016-03-23: client app update +- * 191b2b5 - 2016-03-23: server api update +- * 9bcedac - 2016-03-23: client side settings update - * 7056edd - 2016-03-23: client app setting update - * 6a10c55 - 2016-03-23: test commit 1 - * 957db4d - 2016-03-23: Changed import from csv for cm contacts @@ -46,11 +49,4 @@ - * f0b7a58 - 2016-03-17: Fixed variable set in square for a value with spaces; Fixed list update after create/import in services and contacts - * c0c9cbc - 2016-03-17: moh translate directive - * 3df24db - 2016-03-16: Remove mail in the motion bar controller. I open directly the browser. -- * 7186f36 - 2016-03-16: dashboard tools -- * c46770d - 2016-03-16: client assets languages -- * aefac3a - 2016-03-16: server config socketio.js -- * d82155b - 2016-03-16: server + client side mail -- * 2ce2883 - 2016-03-16: client app dashboard -- * 0f84cc4 - 2016-03-16: server side dashboard + socketio.js -- * 957b565 - 2016-03-16: fixed dashboard create diff --git a/server/api/update/update.controller.js b/server/api/update/update.controller.js index 2d53008..9a87035 100644 --- a/server/api/update/update.controller.js +++ b/server/api/update/update.controller.js @@ -36,15 +36,15 @@ exports.index = function(req, res) { // Get a single update exports.pull = function(req, res) { - return Git + Git .pull('origin', 'test', function(err, data) { console.log('data', data); if (err) { console.error('err', err); - return handleError(res, err); } - return res.sendStatus(201).send(data); }); + + return res.sendStatus(200).send(); }; function handleError(res, err) { -- 1.7.1