The Zurich release has arrived! Interested in new features and functionalities? Click here for more

View rule is not working

sunil10
Tera Contributor

Hello everyone, I have created a view called "Test view" which have only 4 fields and should be applicable to only list view, and this view should be visible to only users of group "Database". I created this view rule but it is not working? It is visible to all the users irrespective of groups

(function overrideView(view, is_list) {

   if (is_list && gs.getUser().isMemberOf('Database')) {
    answer = 'test_view';
}

})(view, is_list);

  

5 REPLIES 5

@sunil10 

So database users are navigated to correct list view but they are able to see the other views?

If my response helped please mark it correct and close the thread so that it benefits future readers.

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader