mirror of
https://github.com/grafana/grafana.git
synced 2025-02-13 09:05:45 -06:00
21 lines
425 B
TypeScript
21 lines
425 B
TypeScript
import _ from 'lodash';
|
|
|
|
export class QueryCtrl {
|
|
target: any;
|
|
datasource: any;
|
|
panelCtrl: any;
|
|
panel: any;
|
|
hasRawMode: boolean;
|
|
error: string;
|
|
isLastQuery: boolean;
|
|
|
|
constructor(public $scope, public $injector) {
|
|
this.panel = this.panelCtrl.panel;
|
|
this.isLastQuery = _.indexOf(this.panel.targets, this.target) === this.panel.targets.length - 1;
|
|
}
|
|
|
|
refresh() {
|
|
this.panelCtrl.refresh();
|
|
}
|
|
}
|