Skip to content

Commit

Permalink
Change terminology for status on weather/traffic/towers plates. Ref #210
Browse files Browse the repository at this point in the history
.
  • Loading branch information
cyoung committed Jan 29, 2016
1 parent 442e882 commit bbbcd3b
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions web/plates/js/traffic.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,16 +61,16 @@ function TrafficCtrl($rootScope, $scope, $state, $http, $interval) {
$scope.socket = socket; // store socket in scope for enter/exit usage
}

$scope.ConnectState = "Not Receiving";
$scope.ConnectState = "Disconnected";

socket.onopen = function (msg) {
// $scope.ConnectStyle = "label-success";
$scope.ConnectState = "Receiving";
$scope.ConnectState = "Connected";
};

socket.onclose = function (msg) {
// $scope.ConnectStyle = "label-danger";
$scope.ConnectState = "Not Receiving";
$scope.ConnectState = "Disconnected";
$scope.$apply();
setTimeout(connect, 1000);
};
Expand Down
6 changes: 3 additions & 3 deletions web/plates/js/weather.js
Original file line number Diff line number Diff line change
Expand Up @@ -154,16 +154,16 @@ function WeatherCtrl($rootScope, $scope, $state, $http, $interval) {
$scope.socket = socket; // store socket in scope for enter/exit usage
}

$scope.ConnectState = "Not Receiving";
$scope.ConnectState = "Disconnected";

socket.onopen = function (msg) {
// $scope.ConnectStyle = "label-success";
$scope.ConnectState = "Receiving";
$scope.ConnectState = "Connected";
};

socket.onclose = function (msg) {
// $scope.ConnectStyle = "label-danger";
$scope.ConnectState = "Not Receiving";
$scope.ConnectState = "Disconnected";
$scope.$apply();
setTimeout(connect, 1000);
};
Expand Down
4 changes: 2 additions & 2 deletions web/plates/towers.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<div class="panel panel-default">
<div class="panel-heading">
<span class="panel_label">Towers</span>
<span ng-show="ConnectState == 'Receiving'" class="label label-success">{{ConnectState}}</span>
<span ng-hide="ConnectState == 'Receiving'" class="label label-danger">{{ConnectState}}</span>
<span ng-show="ConnectState == 'Connected'" class="label label-success">{{ConnectState}}</span>
<span ng-hide="ConnectState == 'Connected'" class="label label-danger">{{ConnectState}}</span>
</div>
<div class="panel-body towers-page">
<div class="row">
Expand Down
4 changes: 2 additions & 2 deletions web/plates/traffic.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<div class="panel panel-default">
<div class="panel-heading">
<span class="panel_label">Traffic</span>
<span ng-show="ConnectState == 'Receiving'" class="label label-success">{{ConnectState}}</span>
<span ng-hide="ConnectState == 'Receiving'" class="label label-danger">{{ConnectState}}</span>
<span ng-show="ConnectState == 'Connected'" class="label label-success">{{ConnectState}}</span>
<span ng-hide="ConnectState == 'Connected'" class="label label-danger">{{ConnectState}}</span>
</div>
<div class="panel-body traffic-page">
<div class="row">
Expand Down
4 changes: 2 additions & 2 deletions web/plates/weather.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<div class="panel panel-default">
<div class="panel-heading">
<span class="panel_label">Weather</span>
<span ng-show="ConnectState == 'Receiving'" class="label label-success">{{ConnectState}}</span>
<span ng-hide="ConnectState == 'Receiving'" class="label label-danger">{{ConnectState}}</span>
<span ng-show="ConnectState == 'Connected'" class="label label-success">{{ConnectState}}</span>
<span ng-hide="ConnectState == 'Connected'" class="label label-danger">{{ConnectState}}</span>
</div>
</div>

Expand Down

0 comments on commit bbbcd3b

Please sign in to comment.