Commit 05fc3453 by Sébastien Bouchex Bellomié

Merge remote-tracking branch 'grafana/master'

parents aba824a3 20d5d0ee
...@@ -24,14 +24,14 @@ function ($, angular, _) { ...@@ -24,14 +24,14 @@ function ($, angular, _) {
$tooltip.appendTo(document.body); $tooltip.appendTo(document.body);
if (opts.compile) { if (opts.compile) {
angular.element(document).injector().invoke(function($compile, $rootScope) { angular.element(document).injector().invoke(["$compile", "$rootScope", function($compile, $rootScope) {
var tmpScope = $rootScope.$new(true); var tmpScope = $rootScope.$new(true);
_.extend(tmpScope, opts.scopeData); _.extend(tmpScope, opts.scopeData);
$compile($tooltip)(tmpScope); $compile($tooltip)(tmpScope);
tmpScope.$digest(); tmpScope.$digest();
//tmpScope.$destroy(); tmpScope.$destroy();
}); }]);
} }
width = $tooltip.outerWidth(true); width = $tooltip.outerWidth(true);
......
...@@ -25,14 +25,14 @@ function (angular, _, config) { ...@@ -25,14 +25,14 @@ function (angular, _, config) {
} }
backendSrv.search(query).then(function(results) { backendSrv.search(query).then(function(results) {
$scope.searchHits = results.dashboards; $scope.searchHits = results;
$scope.filterHits(); $scope.filterHits();
}); });
}; };
$scope.filterHits = function() { $scope.filterHits = function() {
$scope.filteredHits = _.reject($scope.searchHits, function(dash) { $scope.filteredHits = _.reject($scope.searchHits, function(dash) {
return _.findWhere($scope.playlist, {slug: dash.slug}); return _.findWhere($scope.playlist, {uri: dash.uri});
}); });
}; };
......
...@@ -18,7 +18,7 @@ function (angular, _, kbn) { ...@@ -18,7 +18,7 @@ function (angular, _, kbn) {
angular.element(window).unbind('resize'); angular.element(window).unbind('resize');
var dash = self.dashboards[self.index % self.dashboards.length]; var dash = self.dashboards[self.index % self.dashboards.length];
$location.url('dashboard/db/' + dash.slug); $location.url('dashboard/' + dash.uri);
self.index++; self.index++;
self.cancelPromise = $timeout(self.next, self.interval); self.cancelPromise = $timeout(self.next, self.interval);
......
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