mirror of
https://github.com/valitydev/redash.git
synced 2024-11-07 17:38:54 +00:00
Fix: wrong use of Events.record function
This commit is contained in:
parent
f732f30bf0
commit
3981c1c8a7
@ -181,7 +181,7 @@ function DashboardCtrl($rootScope, $routeParams, $location, $timeout, $q, $uibMo
|
||||
};
|
||||
|
||||
this.togglePublished = () => {
|
||||
Events.record(currentUser, 'toggle_published', 'dashboard', this.dashboard.id);
|
||||
Events.record('toggle_published', 'dashboard', this.dashboard.id);
|
||||
this.dashboard.is_draft = !this.dashboard.is_draft;
|
||||
this.saveInProgress = true;
|
||||
Dashboard.save({
|
||||
|
@ -157,7 +157,7 @@ function QueryViewCtrl($scope, Events, $route, $routeParams, $http, $location, $
|
||||
};
|
||||
|
||||
$scope.togglePublished = () => {
|
||||
Events.record(currentUser, 'toggle_published', 'query', $scope.query.id);
|
||||
Events.record('toggle_published', 'query', $scope.query.id);
|
||||
$scope.query.is_draft = !$scope.query.is_draft;
|
||||
$scope.saveQuery(undefined, { is_draft: $scope.query.is_draft });
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user