Skip to content
This repository has been archived by the owner on Dec 24, 2020. It is now read-only.

Commit

Permalink
Adds status count to header
Browse files Browse the repository at this point in the history
  • Loading branch information
douglasg14b committed Apr 11, 2016
1 parent cfb500c commit 6bea334
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions userscript.js
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ function Main(){

//All the HTML that needs to be inserted into the DOM
$('body').prepend(
'<div id="userStatuses" title="{{users.currentUser.canAccessAdmin ? statuses.statusHash[statuses.selectedStatus].customGrouping ? statuses.statusHash[statuses.selectedStatus].groupBy : statuses.statusHash[statuses.selectedStatus].name : statuses.statusHash[users.usersHash[users.currentUser.id].currentStatus].name}} {{users.currentUser.canAccessAdmin ? \'Timers\' : \'Timer\'}}" style="overflow-y:auto;">'+
'<div id="userStatuses" title="{{users.currentUser.canAccessAdmin ? statuses.statusHash[statuses.selectedStatus].customGrouping ? statuses.statusHash[statuses.selectedStatus].groupBy : filterResults.length + \' \' + statuses.statusHash[statuses.selectedStatus].name : statuses.statusHash[users.usersHash[users.currentUser.id].currentStatus].name}} {{users.currentUser.canAccessAdmin ? \'Timers\' : \'Timer\'}}" style="overflow-y:auto;">'+
'<div class="error-message-container hidden"><div class="error-message"></div></div>'+
'<table id="statusTable" class="table table-bordered table-condensed" style="border-radius: 0px; text-align:center;">'+
'<thead>'+
Expand All @@ -85,7 +85,7 @@ function Main(){
'</tr>'+
'</thead>'+
'<tbody>'+
'<tr ng-if="users.currentUser.canAccessAdmin && !statuses.statusHash[statuses.selectedStatus].customGrouping" style="background: hsl({{user.hue}}, 100%, {{user.level}})" ng-repeat="user in users.usersHash | toArray | filter:{currentStatus: statuses.statusHash[statuses.selectedStatus].id} : true | negativeSplitFilter: hideMatchingText | orderBy: ' + "'" + 'timeInStatus' + "'" +':true">'+
'<tr ng-if="users.currentUser.canAccessAdmin && !statuses.statusHash[statuses.selectedStatus].customGrouping" style="background: hsl({{user.hue}}, 100%, {{user.level}})" ng-repeat="user in filterResults = (users.usersHash | toArray | filter:{currentStatus: statuses.statusHash[statuses.selectedStatus].id} : true | negativeSplitFilter: hideMatchingText | orderBy: ' + "'" + 'timeInStatus' + "'" +':true)">'+
'<td><change-user-status-dropdown/></td>'+
'<td ng-if="statuses.selectedStatus == \'busy\' && statuses.statusHash[\'busy\'].showRingGroup"><span style="font-size:0.9em;" ng-repeat="ringGroup in user.ringGroups" class="label label-info">{{ringGroup}}</span></td>'+
'<td>{{user.timeInStatus | date: "H:mm:ss": "UTC"}}</td>'+
Expand Down Expand Up @@ -523,6 +523,7 @@ function Main(){
$scope.hideMatchingText = $scope.config.GetConfig('hideMatchingText') === null ? '' : $scope.config.GetConfig('hideMatchingText');
$scope.offlineWhenClosed = $scope.config.GetConfig('offlineWhenClosed') === null ? true : $scope.config.GetConfig('offlineWhenClosed');
$scope.errors = []; //Unused
$scope.currentUserCount = 0; //User count for selected status

/*==============================
Variable watching for config
Expand Down

0 comments on commit 6bea334

Please sign in to comment.