fix(table): fixed issue with using mixed data source in table panel, fixes #5999

This commit is contained in:
Torkel Ödegaard 2016-09-10 09:56:03 +02:00
parent 7b1c374f64
commit 7aab4a4a59
2 changed files with 4 additions and 1 deletions

View File

@ -15,6 +15,9 @@
### Breaking changes ### Breaking changes
* **SystemD**: Change systemd description, closes [#5971](https://github.com/grafana/grafana/pull/5971) * **SystemD**: Change systemd description, closes [#5971](https://github.com/grafana/grafana/pull/5971)
### Bugfixes
* **Table Panel**: Fixed problem when switching to Mixed datasource in metrics tab, fixes [#5999](https://github.com/grafana/grafana/pull/5999)
# 3.1.2 (unreleased) # 3.1.2 (unreleased)
* **Templating**: Fixed issue when combining row & panel repeats, fixes [#5790](https://github.com/grafana/grafana/issues/5790) * **Templating**: Fixed issue when combining row & panel repeats, fixes [#5790](https://github.com/grafana/grafana/issues/5790)
* **Drag&Drop**: Fixed issue with drag and drop in latest Chrome(51+), fixes [#5767](https://github.com/grafana/grafana/issues/5767) * **Drag&Drop**: Fixed issue with drag and drop in latest Chrome(51+), fixes [#5767](https://github.com/grafana/grafana/issues/5767)

View File

@ -244,7 +244,7 @@ class MetricsPanelCtrl extends PanelCtrl {
if (datasource.meta.mixed) { if (datasource.meta.mixed) {
_.each(this.panel.targets, target => { _.each(this.panel.targets, target => {
target.datasource = this.panel.datasource; target.datasource = this.panel.datasource;
if (target.datasource === null) { if (!target.datasource) {
target.datasource = config.defaultDatasource; target.datasource = config.defaultDatasource;
} }
}); });