Commit 1e4ff1e7 by Torkel Ödegaard

Added config setting for default playlist timespan

parent 0f40e06d
...@@ -2,6 +2,7 @@ vNext ...@@ -2,6 +2,7 @@ vNext
- New Y-axis formater for metric values that represent seconds (Issue #427) - thx @jippi - New Y-axis formater for metric values that represent seconds (Issue #427) - thx @jippi
- Allow special characters in serie names (influxdb datasource), PR #390 - thx @majst01 - Allow special characters in serie names (influxdb datasource), PR #390 - thx @majst01
- Refactoring of filterSrv (Issue #428), thx @Tetha - Refactoring of filterSrv (Issue #428), thx @Tetha
- New config for playlist feature. Set playlist_timespan to set default playlist interval (Issue #445) - thx @rmca
# Fixes # Fixes
- Filter option loading when having muliple nested filters now works better. - Filter option loading when having muliple nested filters now works better.
......
...@@ -25,7 +25,7 @@ function (_, crypto) { ...@@ -25,7 +25,7 @@ function (_, crypto) {
grafana_index : 'grafana-dash', grafana_index : 'grafana-dash',
elasticsearch_all_disabled : false, elasticsearch_all_disabled : false,
timezoneOffset : null, timezoneOffset : null,
playlistTimespan : "15s", playlist_timespan : "1m",
unsaved_changes_warning : true unsaved_changes_warning : true
}; };
......
...@@ -11,7 +11,7 @@ function (angular, _, config) { ...@@ -11,7 +11,7 @@ function (angular, _, config) {
module.controller('PlaylistCtrl', function($scope, playlistSrv) { module.controller('PlaylistCtrl', function($scope, playlistSrv) {
$scope.init = function() { $scope.init = function() {
$scope.timespan = config.playlistTimespan; $scope.timespan = config.playlist_timespan;
$scope.loadFavorites(); $scope.loadFavorites();
$scope.$on('modal-opened', $scope.loadFavorites); $scope.$on('modal-opened', $scope.loadFavorites);
}; };
......
...@@ -14,7 +14,6 @@ function (Settings) { ...@@ -14,7 +14,6 @@ function (Settings) {
* For Basic authentication use: http://username:password@domain.com:9200 * For Basic authentication use: http://username:password@domain.com:9200
*/ */
elasticsearch: "http://"+window.location.hostname+":9200", elasticsearch: "http://"+window.location.hostname+":9200",
playlistTimespan: "15s",
/** /**
* graphite-web url: * graphite-web url:
...@@ -69,6 +68,12 @@ function (Settings) { ...@@ -69,6 +68,12 @@ function (Settings) {
*/ */
unsaved_changes_warning: true, unsaved_changes_warning: true,
/**
* set the default timespan for the playlist feature
* Example: "1m", "1h"
*/
playlist_timespan: "1m",
panel_names: [ panel_names: [
'text', 'text',
'graphite' 'graphite'
......
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