3
0
mirror of https://github.com/grafana/grafana.git synced 2025-02-25 18:55:37 -06:00

Default property that marks which datasource is default in config.js is now optional (Fixes )

This commit is contained in:
Torkel Ödegaard 2014-06-22 18:02:43 +02:00
parent 551771c6cf
commit 9a53779b6c
3 changed files with 5 additions and 1 deletions

View File

@ -9,6 +9,7 @@ vNext
- Bug in when using % sign in legends (aliases), fixed by removing url decoding of metric names (Fixes #506)
- Series names and column name typeahead cache fix (Fixes #522)
- Fixed influxdb issue with raw query that caused wrong value column detection (Fixes #504)
- Default property that marks which datasource is default in config.js is now optional (Fixes #526)
# 1.6.0 (2014-06-16)

View File

@ -15,6 +15,9 @@ function (angular, _, config) {
this.init = function() {
var defaultDatasource = _.findWhere(_.values(config.datasources), { default: true });
if (!defaultDatasource) {
defaultDatasource = config.datasources[_.keys(config.datasources)[0]];
}
this.default = this.datasourceFactory(defaultDatasource);
};

View File

@ -68,7 +68,7 @@ function (angular, _, kbn) {
}
else {
var template = "select [[group]][[group_comma]] [[func]](\"[[column]]\") as \"[[column]]_[[func]]\" from [[series]] " +
var template = "select [[group]][[group_comma]] [[func]]([[column]]) from [[series]] " +
"where [[timeFilter]] [[condition_add]] [[condition_key]] [[condition_op]] [[condition_value]] " +
"group by time([[interval]])[[group_comma]] [[group]] order asc";