1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-07-23 07:19:41 +02:00

Hide masthead after first load

This commit is contained in:
Michael Crosby 2013-09-02 17:18:54 -07:00
parent ef3ec09cad
commit 847c2d570c
3 changed files with 14 additions and 4 deletions

View file

@ -3,9 +3,18 @@ function MastheadController($scope) {
$scope.template = 'partials/masthead.html';
}
function DashboardController($scope, Container) {
function DashboardController($scope, Container, Settings) {
$scope.predicate = '-Created';
$scope.containers = [];
var opts = {animation:false};
if (Settings.firstLoad) {
opts.animation = true;
Settings.firstLoad = false;
$('#masthead').show();
setTimeout(function() {
$('#masthead').slideUp('slow');
}, 5000);
}
Container.query({all: 1}, function(d) {
var running = 0
@ -44,7 +53,7 @@ function DashboardController($scope, Container) {
} // ghost
];
c.Doughnut(data, {});
c.Doughnut(data, opts);
var lgd = $('#chart-legend').get(0);
legend(lgd, data);
});