You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ranger.apache.org by me...@apache.org on 2017/09/19 12:11:52 UTC
ranger git commit: RANGER-1787: User has to fill up all the allow and
deny conditions items to create a knox policy.
Repository: ranger
Updated Branches:
refs/heads/master 83014529e -> d9aff094c
RANGER-1787: User has to fill up all the allow and deny conditions items to create a knox policy.
Project: http://git-wip-us.apache.org/repos/asf/ranger/repo
Commit: http://git-wip-us.apache.org/repos/asf/ranger/commit/d9aff094
Tree: http://git-wip-us.apache.org/repos/asf/ranger/tree/d9aff094
Diff: http://git-wip-us.apache.org/repos/asf/ranger/diff/d9aff094
Branch: refs/heads/master
Commit: d9aff094c7480fa018f2068a463e9338bcb6923a
Parents: 8301452
Author: Nitin Galave <ni...@gmail.com>
Authored: Mon Sep 18 11:20:07 2017 +0530
Committer: Mehul Parikh <me...@apache.org>
Committed: Tue Sep 19 17:41:08 2017 +0530
----------------------------------------------------------------------
.../webapp/scripts/views/policies/PermissionList.js | 12 ++----------
1 file changed, 2 insertions(+), 10 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ranger/blob/d9aff094/security-admin/src/main/webapp/scripts/views/policies/PermissionList.js
----------------------------------------------------------------------
diff --git a/security-admin/src/main/webapp/scripts/views/policies/PermissionList.js b/security-admin/src/main/webapp/scripts/views/policies/PermissionList.js
index 0803945..92b8334 100644
--- a/security-admin/src/main/webapp/scripts/views/policies/PermissionList.js
+++ b/security-admin/src/main/webapp/scripts/views/policies/PermissionList.js
@@ -247,12 +247,8 @@ define(function(require) {
renderPerms :function(){
var that = this;
this.perms = _.map(this.accessTypes,function(m){return {text:m.label, value:m.name};});
- this.perms.push({'value' : -1, 'text' : 'Select/Deselect All'});
- //set default access type 'select' for add new masking & row filter policies
- if(this.perms.length == 2){
- if(!_.isUndefined(this.perms[0].value) && _.isEmpty(this.permsIds)){
- this.permsIds.push(this.perms[0].value);
- }
+ if(this.perms.length > 1){
+ this.perms.push({'value' : -1, 'text' : 'Select/Deselect All'});
}
//create x-editable for permissions
this.ui.addPerms.editable({
@@ -318,10 +314,6 @@ define(function(require) {
this.ui.addPerms.attr('title','Components Permissions')
this.ui.delegatedAdmin.parent('td').hide();
this.perms = _.map(this.accessTypes,function(m){return {text:m.label, value:m.name};});
- //select defatult access type if single component exists
- if(this.perms.length == 1 && this.permsIds.length >= 0){
- this.permsIds.push(this.perms[0].value)
- }
var select2optn = { width :'600px' };
if(XAUtil.isMaskingPolicy(this.rangerPolicyType)){
select2optn = {width :'600px' , maximumSelectionSize : 1 };