mirror of
https://github.com/grafana/grafana.git
synced 2025-02-11 08:05:43 -06:00
13 lines
494 B
TypeScript
13 lines
494 B
TypeScript
import angular from 'angular';
|
|
import { ChangeTracker } from './change_tracker';
|
|
|
|
/** @ngInject */
|
|
export function unsavedChangesSrv(this: any, $rootScope, $q, $location, $timeout, contextSrv, dashboardSrv, $window) {
|
|
this.init = function(dashboard, scope) {
|
|
this.tracker = new ChangeTracker(dashboard, scope, 1000, $location, $window, $timeout, contextSrv, $rootScope);
|
|
return this.tracker;
|
|
};
|
|
}
|
|
|
|
angular.module('grafana.services').service('unsavedChangesSrv', unsavedChangesSrv);
|