Prevent dashboard resolve from sending GET requests until after user logs in

This commit is contained in:
Jared Tabor 2016-06-20 13:08:42 -07:00
parent c9037d2c50
commit bc9289c5a5

View File

@ -247,9 +247,12 @@ var tower = angular.module('Tower', [
label: "DASHBOARD"
},
resolve: {
graphData: ['$q', 'jobStatusGraphData', function($q, jobStatusGraphData) {
return $q.all({
jobStatus: jobStatusGraphData.get("month", "all"),
graphData: ['$q', 'jobStatusGraphData', '$rootScope',
function($q, jobStatusGraphData, $rootScope) {
return $rootScope.featuresConfigured.promise.then(function () {
return $q.all({
jobStatus: jobStatusGraphData.get("month", "all"),
});
});
}]
}