Displaying error message in queue if fails

This commit is contained in:
Gaël Métais
2014-12-29 22:55:52 +01:00
parent f601044645
commit be2911707c
6 changed files with 61 additions and 15 deletions
+5 -1
View File
@@ -1,7 +1,11 @@
.status {
margin: 2em;
margin-top: 2em;
font-size: 2.5em;
}
.statusSubMessage {
font-size: 0.8em;
margin-bottom: 6em;
}
.queueLink {
color: #FFF;
}
@@ -12,6 +12,8 @@ dashboardCtrl.controller('DashboardCtrl', ['$scope', '$rootScope', '$routeParams
$rootScope.loadedResult = result;
$scope.result = result;
init();
}, function(err) {
alert('aie');
});
} else {
$scope.result = $rootScope.loadedResult;
+6 -1
View File
@@ -1,8 +1,13 @@
.status {
margin: 2em;
margin-top: 2em;
font-size: 2.5em;
}
.statusSubMessage {
font-size: 0.8em;
margin-bottom: 6em;
}
.queueLink {
color: #FFF;
}
+19 -8
View File
@@ -1,14 +1,25 @@
<p>Tested url: &nbsp; <a href="{{url}}" target="_blank" class="testedUrl">{{url}}</a></p>
<div ng-if="status.statusCode == 'failed'">
<div class="status">Test failed :(</div>
<div class="status">Test failed</div>
<p class="statusSubMessage">{{status.error}}</p>
<p><a class="queueLink" href="https://github.com/gmetais/YellowLabTools/issues" target="_blank">Report a bug on GitHub</a></p>
<p><a class="queueLink" href="/">Back to index</a></p>
</div>
<div class="status" ng-if="status.statusCode == 'awaiting'">
<ng-pluralize count="status.position" when="{
'one': 'Waiting behind 1 other test',
'other': 'Waiting behind {} other tests'}">
</ng-pluralize></div>
<div class="status" ng-if="status.statusCode == 'running'">Test is running...</div>
<div class="status" ng-if="status.statusCode == 'complete'">Test complete</div>
<div ng-if="status.statusCode == 'awaiting'">
<div class="status">
<ng-pluralize count="status.position" when="{
'one': 'Waiting behind 1 other test',
'other': 'Waiting behind {} other tests'}">
</ng-pluralize>
</div>
<p class="statusSubMessage">(auto-refresh activated)</p>
</div>
<div ng-if="status.statusCode == 'running'">
<div class="status">Test is running...</div>
<p class="statusSubMessage">(auto-refresh activated)</p>
</div>
<div ng-if="status.statusCode == 'complete'">
<div class="status">Test complete</div>
<p class="statusSubMessage">Opening results...</p>
</div>