Commit 039fc296 by Torkel Ödegaard

fix: getting started panel and mark adding data source as done, fixes #9568

parent 7cbb4020
...@@ -75,6 +75,12 @@ export class ElasticDatasource { ...@@ -75,6 +75,12 @@ export class ElasticDatasource {
return this.request('POST', url, data).then(function(results) { return this.request('POST', url, data).then(function(results) {
results.data.$$config = results.config; results.data.$$config = results.config;
return results.data; return results.data;
}).catch(err => {
if (err.data && err.data.error) {
throw {message: 'Elasticsearch error: ' + err.data.error.reason, error: err.data.error};
}
throw err;
}); });
} }
......
...@@ -34,7 +34,7 @@ class GettingStartedPanelCtrl extends PanelCtrl { ...@@ -34,7 +34,7 @@ class GettingStartedPanelCtrl extends PanelCtrl {
check: () => { check: () => {
return $q.when( return $q.when(
datasourceSrv.getMetricSources().filter(item => { datasourceSrv.getMetricSources().filter(item => {
return item.meta.builtIn === false; return item.meta.builtIn !== true;
}).length > 0 }).length > 0
); );
} }
......
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