Commit 14952de2 by Torkel Ödegaard

Merge pull request #4009 from utkarshcmu/viewer-bug

Viewers restricted to edit panel
parents b5dc1727 23167a0b
...@@ -8,7 +8,7 @@ function (angular, coreModule) { ...@@ -8,7 +8,7 @@ function (angular, coreModule) {
coreModule.default.controller('JsonEditorCtrl', function($scope) { coreModule.default.controller('JsonEditorCtrl', function($scope) {
$scope.json = angular.toJson($scope.object, true); $scope.json = angular.toJson($scope.object, true);
$scope.canUpdate = $scope.updateHandler !== void 0; $scope.canUpdate = $scope.updateHandler !== void 0 && $scope.contextSrv.isEditor;
$scope.update = function () { $scope.update = function () {
var newObject = angular.fromJson($scope.json); var newObject = angular.fromJson($scope.json);
......
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