Commit 3a0983d8 by Torkel Ödegaard

Merge branch 'develop' into overview

parents bc7ef286 59c7edfd
...@@ -107,16 +107,6 @@ function (angular, $, config, _) { ...@@ -107,16 +107,6 @@ function (angular, $, config, _) {
return $scope.editorTabs; return $scope.editorTabs;
}; };
$scope.colors = [
"#7EB26D","#EAB839","#6ED0E0","#EF843C","#E24D42","#1F78C1","#BA43A9","#705DA0", //1
"#508642","#CCA300","#447EBC","#C15C17","#890F02","#0A437C","#6D1F62","#584477", //2
"#B7DBAB","#F4D598","#70DBED","#F9BA8F","#F29191","#82B5D8","#E5A8E2","#AEA2E0", //3
"#629E51","#E5AC0E","#64B0C8","#E0752D","#BF1B00","#0A50A1","#962D82","#614D93", //4
"#9AC48A","#F2C96D","#65C5DB","#F9934E","#EA6460","#5195CE","#D683CE","#806EB7", //5
"#3F6833","#967302","#2F575E","#99440A","#58140C","#052B51","#511749","#3F2B5B", //6
"#E0F9D7","#FCEACA","#CFFAFF","#F9E2D2","#FCE2DE","#BADFF4","#F9D9F9","#DEDAF7" //7
];
$scope.init(); $scope.init();
}); });
}); });
...@@ -29,6 +29,16 @@ function (angular, config, _) { ...@@ -29,6 +29,16 @@ function (angular, config, _) {
$rootScope.$emit(name, payload); $rootScope.$emit(name, payload);
}; };
$rootScope.colors = [
"#7EB26D","#EAB839","#6ED0E0","#EF843C","#E24D42","#1F78C1","#BA43A9","#705DA0", //1
"#508642","#CCA300","#447EBC","#C15C17","#890F02","#0A437C","#6D1F62","#584477", //2
"#B7DBAB","#F4D598","#70DBED","#F9BA8F","#F29191","#82B5D8","#E5A8E2","#AEA2E0", //3
"#629E51","#E5AC0E","#64B0C8","#E0752D","#BF1B00","#0A50A1","#962D82","#614D93", //4
"#9AC48A","#F2C96D","#65C5DB","#F9934E","#EA6460","#5195CE","#D683CE","#806EB7", //5
"#3F6833","#967302","#2F575E","#99440A","#58140C","#052B51","#511749","#3F2B5B", //6
"#E0F9D7","#FCEACA","#CFFAFF","#F9E2D2","#FCE2DE","#BADFF4","#F9D9F9","#DEDAF7" //7
];
$scope.init(); $scope.init();
}); });
......
...@@ -267,7 +267,7 @@ function (angular, app, $, _, kbn, moment, timeSeries) { ...@@ -267,7 +267,7 @@ function (angular, app, $, _, kbn, moment, timeSeries) {
$scope.seriesHandler = function(seriesData, index) { $scope.seriesHandler = function(seriesData, index) {
var datapoints = seriesData.datapoints; var datapoints = seriesData.datapoints;
var alias = seriesData.target; var alias = seriesData.target;
var color = $scope.panel.aliasColors[alias] || $scope.colors[index]; var color = $scope.panel.aliasColors[alias] || $rootScope.colors[index];
var yaxis = $scope.panel.aliasYAxis[alias] || 1; var yaxis = $scope.panel.aliasYAxis[alias] || 1;
var seriesInfo = { var seriesInfo = {
......
...@@ -37,8 +37,8 @@ define([ ...@@ -37,8 +37,8 @@ define([
} }
}; };
self.scope.colors = []; $rootScope.colors = [];
for (var i = 0; i < 50; i++) { self.scope.colors.push('#' + i); } for (var i = 0; i < 50; i++) { $rootScope.colors.push('#' + i); }
self.$q = $q; self.$q = $q;
self.scope.skipDataOnInit = true; self.scope.skipDataOnInit = true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment