mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
ux: minor navbar update
This commit is contained in:
@@ -59,6 +59,7 @@ export class DataSourceEditCtrl {
|
||||
initNewDatasourceModel() {
|
||||
this.isNew = true;
|
||||
this.current = angular.copy(defaults);
|
||||
this.navModel.items.push({title: 'New data source'});
|
||||
|
||||
// We are coming from getting started
|
||||
if (this.$location.search().gettingstarted) {
|
||||
@@ -85,10 +86,13 @@ export class DataSourceEditCtrl {
|
||||
this.backendSrv.get('/api/datasources/' + id).then(ds => {
|
||||
this.isNew = false;
|
||||
this.current = ds;
|
||||
this.navModel.items.push({title: ds.name});
|
||||
|
||||
if (datasourceCreated) {
|
||||
datasourceCreated = false;
|
||||
this.testDatasource();
|
||||
}
|
||||
|
||||
return this.typeChanged();
|
||||
});
|
||||
}
|
||||
|
||||
@@ -4,7 +4,8 @@
|
||||
<div class="page-header">
|
||||
<h1>
|
||||
<i class="icon-gf icon-gf-datasources"></i>
|
||||
Settings <span ng-show="ctrl.isNew" class="muted">(new)</span>
|
||||
<span ng-show="ctrl.isNew">New data source</span>
|
||||
<span ng-hide="ctrl.isNew">{{ctrl.current.name}}</span>
|
||||
</h1>
|
||||
|
||||
<a class="page-header__cta btn btn-success" href="datasources/new" ng-show="ctrl.isNew">
|
||||
|
||||
Reference in New Issue
Block a user