mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
typescript: updated tslint and fixed new warnings
This commit is contained in:
@@ -69,7 +69,7 @@ export class AnnotationsEditorCtrl {
|
||||
this.reset();
|
||||
this.mode = 'list';
|
||||
this.$scope.broadcastRefresh();
|
||||
};
|
||||
}
|
||||
|
||||
add() {
|
||||
this.annotations.push(this.currentAnnotation);
|
||||
@@ -77,7 +77,7 @@ export class AnnotationsEditorCtrl {
|
||||
this.mode = 'list';
|
||||
this.$scope.broadcastRefresh();
|
||||
this.$scope.dashboard.updateSubmenuVisibility();
|
||||
};
|
||||
}
|
||||
|
||||
removeAnnotation(annotation) {
|
||||
var index = _.indexOf(this.annotations, annotation);
|
||||
|
||||
@@ -216,7 +216,6 @@ coreModule.directive('panelDropZone', function($timeout) {
|
||||
}
|
||||
|
||||
if (indrag === true) {
|
||||
var dropZoneSpan = 12 - row.span;
|
||||
if (dropZoneSpan > 1) {
|
||||
return showPanel(dropZoneSpan, 'Drop Here');
|
||||
}
|
||||
|
||||
@@ -60,7 +60,7 @@ class TimeSrv {
|
||||
if (_.isString(this.time.to) && this.time.to.indexOf('Z') >= 0) {
|
||||
this.time.to = moment(this.time.to).utc();
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private parseUrlParam(value) {
|
||||
if (value.indexOf('now') !== -1) {
|
||||
@@ -92,7 +92,7 @@ class TimeSrv {
|
||||
if (params.refresh) {
|
||||
this.refresh = params.refresh || this.refresh;
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
private routeUpdated() {
|
||||
var params = this.$location.search();
|
||||
@@ -154,7 +154,7 @@ class TimeSrv {
|
||||
|
||||
private cancelNextRefresh() {
|
||||
this.timer.cancel(this.refreshTimer);
|
||||
};
|
||||
}
|
||||
|
||||
setTime(time, fromRouteUpdate?) {
|
||||
_.extend(this.time, time);
|
||||
|
||||
@@ -136,7 +136,7 @@ class MetricsPanelCtrl extends PanelCtrl {
|
||||
this.calculateInterval();
|
||||
|
||||
return this.datasource;
|
||||
};
|
||||
}
|
||||
|
||||
calculateInterval() {
|
||||
var intervalOverride = this.panel.interval;
|
||||
@@ -194,7 +194,7 @@ class MetricsPanelCtrl extends PanelCtrl {
|
||||
if (this.panel.hideTimeOverride) {
|
||||
this.timeInfo = '';
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
issueQueries(datasource) {
|
||||
this.datasource = datasource;
|
||||
|
||||
@@ -74,7 +74,7 @@ export class PlaylistEditCtrl {
|
||||
return playlistItem === listedPlaylistItem;
|
||||
});
|
||||
this.filterFoundPlaylistItems();
|
||||
};
|
||||
}
|
||||
|
||||
savePlaylist(playlist, playlistItems) {
|
||||
var savePromise;
|
||||
|
||||
@@ -154,7 +154,7 @@ export class DataSourceEditCtrl {
|
||||
this.$location.path('datasources/edit/' + result.id);
|
||||
});
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
confirmDelete() {
|
||||
this.backendSrv.delete('/api/datasources/' + this.current.id).then(() => {
|
||||
|
||||
@@ -17,4 +17,4 @@ export {
|
||||
CustomVariable,
|
||||
ConstantVariable,
|
||||
AdhocVariable,
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user