@@ -10,7 +10,12 @@ app.controller('infoscreen_main', function($scope,$http,$timeout){
|
|||||||
$scope.index = -1;
|
$scope.index = -1;
|
||||||
$http.get('/infoscreen/rotation/'+$scope.rotation, {timeout:5000}).then(function(response){
|
$http.get('/infoscreen/rotation/'+$scope.rotation, {timeout:5000}).then(function(response){
|
||||||
templates = response.data.instances;
|
templates = response.data.instances;
|
||||||
$scope.next();
|
if (templates.length == 0) {
|
||||||
|
$timeout(get_rotation, 10000);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
$scope.next();
|
||||||
|
}
|
||||||
},function(response){
|
},function(response){
|
||||||
$timeout(get_rotation, 10000);
|
$timeout(get_rotation, 10000);
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user