This is an automated email from the ASF dual-hosted git repository.

ni3galave pushed a commit to branch ranger-2.3
in repository https://gitbox.apache.org/repos/asf/ranger.git

commit 1793c76b8f4085bad17be416cd6dae7cad27a0e1
Author: Dhaval.Rajpara <[email protected]>
AuthorDate: Wed Mar 16 17:26:08 2022 +0530

    RANGER-3660 : [Ranger Admin UI] Improvements in tooltip hints for better 
user experience
    
    Signed-off-by: Nitin Galave <[email protected]>
---
 .../src/main/webapp/scripts/modules/globalize/message/en.js       | 2 +-
 .../webapp/scripts/views/policies/NRangerPolicyTableLayout.js     | 7 +++----
 .../main/webapp/scripts/views/policies/RangerPolicyTableLayout.js | 8 +++-----
 3 files changed, 7 insertions(+), 10 deletions(-)

diff --git 
a/security-admin/src/main/webapp/scripts/modules/globalize/message/en.js 
b/security-admin/src/main/webapp/scripts/modules/globalize/message/en.js
index 46e4c19..1a54883 100644
--- a/security-admin/src/main/webapp/scripts/modules/globalize/message/en.js
+++ b/security-admin/src/main/webapp/scripts/modules/globalize/message/en.js
@@ -379,7 +379,7 @@ define(function(require) {
                 type                        :'Policy for all type.',
                 udf                         :'Hive udf.',
                 pluginStatus                :'Plugin Status',
-                clusterName                 :'Name of ambari cluster',
+                clusterName                 :'Name of cluster',
                 zoneName                    :"Name of Zone",
                 policyVersion               :'Policy Version',
                 url                                            :'Hive url.',
diff --git 
a/security-admin/src/main/webapp/scripts/views/policies/NRangerPolicyTableLayout.js
 
b/security-admin/src/main/webapp/scripts/views/policies/NRangerPolicyTableLayout.js
index 18664f7..64c7291 100644
--- 
a/security-admin/src/main/webapp/scripts/views/policies/NRangerPolicyTableLayout.js
+++ 
b/security-admin/src/main/webapp/scripts/views/policies/NRangerPolicyTableLayout.js
@@ -514,7 +514,8 @@ define(function(require) {
                 var resourceSearchOpt = _.map(resources, function(resource) {
                     return {
                         'name': resource.name,
-                        'label': resource.label
+                        'label': resource.label,
+                        'description':resource.description
                     };
                 });
                 var PolicyStatusValue = _.map(XAEnums.ActiveStatus, 
function(status) {
@@ -561,8 +562,6 @@ define(function(require) {
                     info :localization.tt('h.roleMsg'),
                     urlLabel : 'roleName'
                 }];
-                // {text : 'Start Date',label :'startDate'},{text : 'End 
Date',label :'endDate'},
-                //  {text : 'Today',label :'today'}];
                 var info = {
                     collection: localization.tt('h.collection'),
                     column: localization.tt('lbl.columnName'),
@@ -594,7 +593,7 @@ define(function(require) {
                     return {
                         'text': opt.label,
                         'label': 'resource:' + opt.name,
-                        'info': info[opt.name],
+                        'info': !_.isUndefined(info[opt.name]) ? 
info[opt.name] : opt.description,
                         'urlLabel': 
XAUtil.stringToCamelCase(opt.label.toLowerCase()),
                     };
                 });
diff --git 
a/security-admin/src/main/webapp/scripts/views/policies/RangerPolicyTableLayout.js
 
b/security-admin/src/main/webapp/scripts/views/policies/RangerPolicyTableLayout.js
index c20bcb9..844d671 100644
--- 
a/security-admin/src/main/webapp/scripts/views/policies/RangerPolicyTableLayout.js
+++ 
b/security-admin/src/main/webapp/scripts/views/policies/RangerPolicyTableLayout.js
@@ -466,7 +466,7 @@ define(function(require){
                                 resources = 
this.rangerServiceDefModel.get('rowFilterDef')['resources'];
                         }
                         var resourceSearchOpt = _.map(resources, 
function(resource){
-                                        return { 'name' : resource.name, 
'label' : resource.label };
+                                        return { 'name' : resource.name, 
'label' : resource.label, 'description':resource.description };
                         });
                        var PolicyStatusValue = _.map(XAEnums.ActiveStatus, 
function(status) { return { 'label': status.label, 'value': 
Boolean(status.value)}; });
        
@@ -479,9 +479,7 @@ define(function(require){
                                                {text : "Role Name",   label 
:"role" ,  info :localization.tt('h.roleMsg'), urlLabel : 'roleName'},
                                                {text : "Policy Label",   label 
:"policyLabelsPartial" ,  info :localization.tt('h.policyLabelsinfo'), urlLabel 
: 'policyLabel'},
                                                ];
-                                            // {text : 'Start Date',label 
:'startDate'},{text : 'End Date',label :'endDate'},
-                                                //  {text : 'Today',label 
:'today'}];
-                        var info = { collection : 
localization.tt('h.collection')    , column   
:localization.tt('lbl.columnName'),
+                                   var info = { collection : 
localization.tt('h.collection')    , column   
:localization.tt('lbl.columnName'),
                                          
'column-family':localization.tt('msg.columnfamily') , database 
:localization.tt('h.database'),
                                           entity        
:localization.tt('h.entity') , keyname  :localization.tt('lbl.keyName'),
                                           path:localization.tt('h.path'), 
queue: localization.tt('h.queue'), service:localization.tt('h.serviceNameMsg'),
@@ -497,7 +495,7 @@ define(function(require){
                                         return {
                                                 'text': opt.label,
                                                 'label': 'resource:'+ opt.name,
-                                                'info' : info[opt.name],
+                                                'info' : 
!_.isUndefined(info[opt.name]) ? info[opt.name] : opt.description,
                                                 'urlLabel' : 
XAUtil.stringToCamelCase(opt.label.toLowerCase()),
                                         };
                        });

Reply via email to