Favorite section items (from \$m.do ) are not showing on ServiceNow app

Pratyush Mandal
Mega Expert

We have default favorite icons in the system for mobile. When we are using $m.do then all favorites are showing in the home page but when we are using Mobile App, those are not showing, in app only those items are showing which are marked as "Favorite" from the desktop view.

Is there way to fix this issue so that all favorite items from system should also visible in mobile app also.

And if in case its not possible we need to set some default favorite icons in the app, so if this will not work then this becomes challenge for us to set default favorite to all users. We want some automate so that we can set some favorite icons as default for all users.app home page.PNG

$m home page.PNG

1 ACCEPTED SOLUTION

Thank you for marking it helpful. If it is answered, can you mark it correct? Refer to this video around 20:15 mark to see how.



Ask the Expert: Community Etiquette, TechNow Ep 27


View solution in original post

19 REPLIES 19

Let me know if you need help with the script to create those records.


Yes that will also help me if you provide the script so that I can try to my one instance,


Here you go. Run this from scripts background.



// get a list of all active users who have already logged in


var u = new GlideRecord('sys_user');


u.addActiveQuery();


u.addNotNullQuery('last_login_time');


u.query();



while (u.next()) {


  // Create a bookmark for this user


  var b = new GlideRecord('sys_ui_bookmark');


  b.newRecord();


  b.icon = 'list';                     // Choose appropriate icon


  b.color = 'yellow';               // Choose your favorite color


  b.auto_add = true;


  b.user = u.getValue('sys_id');


  b.title = 'My incidents';


  b.url = 'YOUR URL HERE';   // Use your appropriate URL


  b.insert();


  gs.log('Bookmark created for: ' + u.getDisplayValue());


}



If you want to run a sample of the first 5 users, add this line between lines 4 and 5



u.setLimit(5);


Now have I answered your question. (I'm eager to see the icon on this discussion turn green.)


Thank you for marking it helpful. If it is answered, can you mark it correct? Refer to this video around 20:15 mark to see how.



Ask the Expert: Community Etiquette, TechNow Ep 27