Skip navigation

Developer Community

1 Post authored by: Igar Bental Employee

You can create new modules and set up favorites on the Mobile UI by configuring the URLs that they navigate to. Using specific URLs formats in ServiceNow, you can create modules, favorites, and UI Actions that route to the correct pages.

 

When using the mobile interface to interact with your instance, you will notice a certain URL format which is kept throughout the whole navigation: type_of_link/table/parameters. Think of this format as the main ingredient to your configured navigation URLs you create for your phone or tablet. You can add other "ingredients" to compliment your main ingredient to build your customized navigation.

 

Customized navigation is used when creating:

Menu Modules: define which modules are available to mobile

users at the application menu or module level.

Screen Shot 2015-09-02 at 3.01.39 PM.png

Homepage Favorites:  is a list of icons that appears on your mobile homepage.

These can be used to create a shortcut to any record, list, form or catalog item.

Screen Shot 2015-09-02 at 3.01.57 PM.png
UI Actions: using the function action.setRedirectURL()Screen Shot 2015-09-02 at 3.01.12 PM.png

 

More information can be found here: Configuring the Smartphone Interface - ServiceNow Wiki

 

You can use the different navigations to create direct links to important aspects of your instance. This allows you to manage the helm while on-the-go, in a meeting, on a call, or while out to lunch from within the Mobile UI:

 

FormatDescriptionExample
list/{tableName}/q:{QUERY}Directing to a list with the applied query (optional)

list/incident/q:active=true^priority=1^EQ

List of incidents where active=true and priority=1

streams/{tableName}/q:{QUERY}Directing to Journal streams of the table records with the applied query (optional)

streams/incident/q:active=true^priority=1^EQ

Journal stream of the incident table where active=true and priority=1

form/{tableName}/{sysId}Directing to a record form

form/incident/a9a16740c61122760004fe9095b7ddca

Record form of incident where sys_id=a9a16740c61122760004fe9095b7ddca

form/{tableName}/-1Directing to a new record form

form/incident/-1

Creating a new incident record

catalog/home/{catalogSysId}Directing to a specific catalog

home/e0d08b13c3330100c8b837659bba8fb4

Catalog homepage of the catalog where sys_id=home/e0d08b13c3330100c8b837659bba8fb4 (Service Catalog)

catalog/category/{categorySysId}/

{categoryName}

Directing to a specific catalog category

catalog/category/d258b953c611227a0146101fb1be7c31/

Hardware

Catalog category 'Hardware'

catalog_item/item/{categorySysId}/

{categoryName}/{itemSysId}

Directs to a specific catalog item

catalog_item/item/d258b953c611227a0146101fb1be7c31/

Hardware/0d08837237153000158bbfc8bcbe5d02

Catalog item form category 'Hardware' where item sys_id=0d08837237153000158bbfc8bcbe5d02

help/{mobileHelpPath}Directs to a Mobile Help page

help/defining_tags

Mobile Help page 'Defining Tags'

view/{UIMacroName}Renders a customized UI Macro

view/test_mobile

Rendering the UI Macro named test_mobile


When directing to a list or stream (the first two options), you can add a query in order to get filtered records. It is quite tricky to build the query yourself so here is a tip to add the query: Always use the module form in order to create the query.

 

Using the Module form to Create a query:

1. Go to System Mobile UI > Navigator Apps. Enter one of the already existing Applications and create a new module in the Modules related list.

sn module query1.jpg

2. Select the table in the Table field, and build the required filter using the Filter Builder. Then save your changes.

sn module query 2.jpg

3. In the Mobile user interface, navigate to the temporary module you just created, and copy the URL part that you need form the browser address bar.

Screen Shot 2015-09-02 at 3.01.39 PM.png

example url.jpg

4. Now you can use this url also as a favorite link. For example:  list/incident/q:caller_idDYNAMIC90d1921e5f510100a9ad2572f2b477fe%5Eshort_descriptionLIKETTT%5EEQ

 

A few things to note...

  • When having a query in the URL, you have probably notices that it can be dynamic, by containing a javascript function.

     For example: list/incident/q:sys_created_onONThis%20month@javascript:gs.beginningOfThisMonth()@javascript:gs.endOfThisMonth()%5EEQ

      • It means, list of incidents which were created this month.
  • The url always starts with an exclamation mark '!'. The exclamation mark is being added by the platform, therefore you don't need to add it.
    • For example:http://<instance_name>.service-now.com/$m.do#/!list/incident/q:active=true%5EEQ
  • When navigating by navigation menu modules or favorites, the platform mechanism was designed in a way that you are kept always inside the instance.

        Therefore, you always have to use relative URLs and not absolute ones.

    • For example: list/incident/q:active=true%5EEQ
      • And not:http://<instance_name>.service-now.com/$m.do#/!list/incident/q:active=true%5EEQ
  • You can not direct navigation menu modules and favorites to external links. UI Actions are a different story, since you are using the function action.setRedirectURL(), where you can send an absolute URL as the function parameter.

 

In this world where we are being stretched thinner and are expected to have a great output, we need to utilize the resources we have. ServiceNow mobile and tablet capabilities are a great way to get more done in the office and still venture away from your desk.

 

Additional resources on using the ServiceNow mobile interface:

Debugging the Mobile UI from your Desktop

List Filtering in the Mobile UI

Mobile View Basics (KB0551074)

Filter Blog

By date: By tag: