���ѧۧݧ�ӧ�� �ާ֧ߧ֧էا֧� - ���֧էѧܧ�ڧ��ӧѧ�� - /home/alphpwcp/public_html/us/alphachat/design/defaulttheme/js/angular.lhc.online.min.js
���ѧ٧ѧ�
services.factory("OnlineUsersFactory",["$http","$q",function(t,e){return this.loadOnlineUsers=function(n){var i=e.defer();return t.get(WWW_DIR_JAVASCRIPT+"chat/onlineusers/(method)/ajax/(timeout)/"+n.timeout+(n.department_dpgroups.length>0?"/(department_dpgroups)/"+n.department_dpgroups.join("/"):"")+(n.department.length>0?"/(department)/"+n.department.join("/"):"")+(n.max_rows>0?"/(maxrows)/"+n.max_rows:"")+(""!=n.country?"/(country)/"+n.country:"")+(""!=n.time_on_site?"/(timeonsite)/"+encodeURIComponent(n.time_on_site):"")).then((function(t){i.resolve(t.data)})),i.promise},this.setLocalSettings=function(n,i){var o=e.defer();return t.post(WWW_DIR_JAVASCRIPT+"front/settings",{attr:n,val:i}).then((function(t){o.resolve(t.data)}),(function(t){o.reject(void 0!==t.status?"["+t.status+"]":"[0]")})),o.promise},this.deleteOnlineUser=function(n){var i=e.defer();return t.post(WWW_DIR_JAVASCRIPT+"chat/onlineusers/(deletevisitor)/"+n.user_id+"/(csfr)/"+confLH.csrf_token).then((function(t){void 0!==t.error_url?document.location=t.data.error_url:i.resolve(t.data)})),i.promise},this}]),lhcAppControllers.controller("OnlineCtrl",["$scope","$http","$location","$rootScope","$log","$interval","$window","OnlineUsersFactory",function(t,e,n,i,o,r,s,a){var l;this.onlineusers=[],this.onlineusers_tt=0,this.onlineusersPreviousID=[],t.onlineusersGrouped=[],this.updateTimeout="10",this.userTimeout="3600",this.maxRows="50",this.department=[],this.department_dpgroups=[],this.country="none",this.predicate="last_visit",this.time_on_site="",this.reverse=!0,this.wasInitiated=!1,this.online_connected=!1,this.attrf_key_1="",this.attrf_val_1="",this.attrf_key_2="",this.attrf_val_2="",this.attrf_key_3="",this.attrf_val_3="",this.attrf_key_4="",this.attrf_val_4="",this.attrf_key_5="",this.attrf_val_5="",this.forbiddenVisitors=!1,this.soundEnabled=!1,this.notificationEnabled=!1,this.lastSyncSkipped=!1;var _=this;!0!==_.forbiddenVisitors&&["onlineusers","widget-onvisitors","map","dashboard"].forEach((function(t){var e=document.getElementById(t);null!==e&&new MutationObserver((function(t){e.classList.contains("active")&&1==_.lastSyncSkipped&&_.updateList()})).observe(e,{attributes:!0,attributeFilter:["class"],childList:!1,characterData:!1})})),t.groupByField="none",t.groupBy=function(e){var n,i;t.onlineusersGrouped=[],n=_.onlineusers,i=e,n.sort((function(t,e){return t[i]<=e[i]?-1:1}));for(var o="_INVALID_GROUP_VALUE_",r=0;r<_.onlineusers.length;r++){var s=_.onlineusers[r];if(s[e]!==o){var a={label:s[e],id:r,ou:[]};o=a.label,t.onlineusersGrouped.push(a)}a.ou.push(s)}},this.updateList=function(){if(1!=lhinst.disableSync&&1!=_.forbiddenVisitors){var e=!1,n=document.getElementById("onlineusers");if(null!==n&&(e=n.classList.contains("active")),0==e){var i=document.getElementById("map");null!==i&&(e=i.classList.contains("active"))}if(0==e)if(null!==document.getElementById("widget-onvisitors-body")){var o=document.getElementById("dashboard");null!==o&&o.classList.contains("active")&&(e=!0)}!1!==e?(_.lastSyncSkipped=!1,a.loadOnlineUsers({department_dpgroups:_.department_dpgroups,timeout:_.userTimeout,time_on_site:_.time_on_site,department:_.department,country:_.country,max_rows:_.maxRows}).then((function(e){if(_.onlineusers=e.list,_.onlineusers_tt=e.tt,"none"!=t.groupByField?t.groupBy(t.groupByField):(t.onlineusersGrouped=[],t.onlineusersGrouped.push({label:"",id:0,ou:_.onlineusers})),ee.emitEvent("chatAdminSyncOnlineVisitors",[e.list]),_.notificationEnabled||_.soundEnabled){var n=!1,i=[];if(angular.forEach(_.onlineusers,(function(t,e){var o=!0;-1==_.onlineusersPreviousID.indexOf(t.id)&&(o=!1,_.onlineusersPreviousID.push(t.id)),1==_.wasInitiated&&0==o&&(n=!0,i.push(t))})),1==n){if(_.soundEnabled&&Modernizr.audio){var o=new Audio;o.src=Modernizr.audio.ogg?WWW_DIR_JAVASCRIPT_FILES+"/new_visitor.ogg":Modernizr.audio.mp3?WWW_DIR_JAVASCRIPT_FILES+"/new_visitor.mp3":WWW_DIR_JAVASCRIPT_FILES+"/new_visitor.wav",o.load(),setTimeout((function(){o.play()}),500)}_.notificationEnabled&&(window.webkitNotifications||window.Notification)&&angular.forEach(i,(function(t,e){if(window.webkitNotifications)0==window.webkitNotifications.checkPermission()&&((n=window.webkitNotifications.createNotification(WWW_DIR_JAVASCRIPT_FILES_NOTIFICATION+"/notification.png",t.ip+(""!=t.user_country_name?", "+t.user_country_name:""),(""!=t.page_title?t.page_title+"\n-----\n":"")+(""!=t.referrer?t.referrer+"\n-----\n":""))).onclick=function(){n.cancel()},n.show(),setTimeout((function(){n.cancel()}),15e3));else if(window.Notification){var n;if("granted"==window.Notification.permission)(n=new Notification(t.ip+(""!=t.user_country_name?", "+t.user_country_name:""),{icon:WWW_DIR_JAVASCRIPT_FILES_NOTIFICATION+"/notification.png",body:(""!=t.page_title?t.page_title+"\n-----\n":"")+(""!=t.referrer?t.referrer+"\n-----\n":"")})).onclick=function(){n.close()},setTimeout((function(){n.close()}),15e3)}}))}_.wasInitiated=!0,_.onlineusersPreviousID.length>100&&(_.wasInitiated=!1,_.onlineusersPreviousID=[])}}))):_.lastSyncSkipped=!0}},l=r((function(){0==_.forbiddenVisitors?_.updateList():r.cancel(l)}),1e3*this.updateTimeout),t.$watch("online.updateTimeout",(function(t,e){t!=e&&(r.cancel(l),l=r((function(){_.updateList()}),1e3*t),lhinst.changeUserSettingsIndifferent("oupdate_timeout",t))})),t.$watch("online.userTimeout",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("ouser_timeout",t)})),t.$watch("online.country",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("ocountry",t)})),t.$watch("online.time_on_site",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("otime_on_site",""==t?"none":t)})),t.$watch("online.maxRows",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("omax_rows",t)})),t.$watch("online.attrf_key_1",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_key_1",t)})),t.$watch("online.attrf_val_1",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_val_1",t)})),t.$watch("online.attrf_key_2",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_key_2",t)})),t.$watch("online.attrf_val_2",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_val_2",t)})),t.$watch("online.attrf_key_3",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_key_3",t)})),t.$watch("online.attrf_val_3",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_val_3",t)})),t.$watch("online.attrf_key_4",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_key_4",t)})),t.$watch("online.attrf_val_4",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_val_4",t)})),t.$watch("online.attrf_key_5",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_key_5",t)})),t.$watch("online.attrf_val_5",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("oattrf_val_5",t)})),this.departmentChanged=function(t){a.setLocalSettings(t+"_online",this[t])},this.productChanged=function(t){a.setLocalSettings(t+"_online",this[t])},t.$watch("groupByField",(function(t,e){t!=e&&lhinst.changeUserSettingsIndifferent("ogroup_by",t)})),t.$watch("online.userTimeout + online.department + online.department_dpgroups + online.maxRows + groupByField + online.country + online.time_on_site + online.attrf_key_1 + online.attrf_val_1 + online.attrf_key_2 + online.attrf_val_2 + online.attrf_key_3 + online.attrf_val_3 + online.attrf_key_4 + online.attrf_val_4 + online.attrf_key_5 + online.attrf_val_5",(function(t,e){setTimeout((function(){_.updateList()}),500)})),this.showOnlineUserInfo=function(t){lhc.revealModal({url:WWW_DIR_JAVASCRIPT+"chat/getonlineuserinfo/"+t})},this.previewChat=function(t){t.chat_id>0&&1==t.can_view_chat&&lhc.revealModal({url:WWW_DIR_JAVASCRIPT+"chat/previewchat/"+t.chat_id})},this.sendMessage=function(t){lhc.revealModal({url:WWW_DIR_JAVASCRIPT+"chat/sendnotice/"+t})},this.deleteUser=function(t,e){confirm(e)&&a.deleteOnlineUser({user_id:t.id}).then((function(e){_.onlineusers.splice(_.onlineusers.indexOf(t),1)}))},this.disableNewUserBNotif=function(){_.notificationEnabled=!_.notificationEnabled,lhinst.changeUserSettings("new_user_bn",1==_.notificationEnabled?1:0)},this.showConnected=function(){_.online_connected=!_.online_connected,lhinst.changeUserSettings("online_connected",1==_.online_connected?1:0)},this.disableNewUserSound=function(){_.soundEnabled=!_.soundEnabled,lhinst.changeUserSettings("new_user_sound",1==_.soundEnabled?1:0)},this.initController=function(){s.onlineAttributeFilter&&(this.attrf_key_1=s.onlineAttributeFilter.attrf_key_1,this.attrf_val_1=s.onlineAttributeFilter.attrf_val_1,this.attrf_key_2=s.onlineAttributeFilter.attrf_key_2,this.attrf_val_2=s.onlineAttributeFilter.attrf_val_2,this.attrf_key_3=s.onlineAttributeFilter.attrf_key_3,this.attrf_val_3=s.onlineAttributeFilter.attrf_val_3,this.attrf_key_4=s.onlineAttributeFilter.attrf_key_4,this.attrf_val_4=s.onlineAttributeFilter.attrf_val_4,this.attrf_key_5=s.onlineAttributeFilter.attrf_key_5,this.attrf_val_5=s.onlineAttributeFilter.attrf_val_5)},t.$on("$destroy",(function(){r.cancel(l)}))}]);
| ver. 1.4 |
Github
|
.
| PHP 8.2.30 | ���֧ߧ֧�ѧ�ڧ� ����ѧߧڧ��: 0 |
proxy
|
phpinfo
|
���ѧ����ۧܧ�