Create Pop Up after click on button (start work) in Mobile Agent App

SunilM
Tera Contributor

we have start work button on WOT table which is OOB in mobile agent app as well as the back office, In the back office after clicking on the start work UI action button its checks does the task has a Upstream task or not if yes it will open pop up window  I have to implement same in mobile agent App can someone help me with this 

4 REPLIES 4

BharathChintala
Mega Sage

@SunilM The pop up your are talking about is a UI page.

 

If there is one pop up already coming when you clicked. That means from UI action you are calling it using dialogClass

 

If not use below script to call a UI Page

var dialogClass = self.window.GlideModal ? GlideModal : GlideDialogWindow;
    var dialog = new dialogClass('time_sheet_recall_dialogue');// replace ui page name here.
    dialog.setTitle(new GwtMessage().getMessage('Recall Time Card'));// Pop name replace here
    dialog.setPreference('sysparm_sys_id',checkedSysIds);// to pass data from UI action to UI page replace checkedSysIds with your variable
    dialog.setPreference('sysparm_record_name', 'time_card'); to pass data from UI action to UI page replace checkedSysIds with your variable
    dialog.setPreference('sysparm_record_title', warningTitle);
    dialog.setWidth(300);
    dialog.render();
If my inputs have helped with your question, please mark my answer as accepted solution, and give a thumb up.
Bharath Chintala

SunilM
Tera Contributor

@BharathChintala Thank you for the inputs.
Yes we have already UI page for Desktop but I need to create same pop up based on script include (checkUpstreamTask) results for the mobile app 

Erik Stolberg
Tera Guru

Older post, but this is now a configuration option - Mobile pop-ups:
https://docs.servicenow.com/bundle/washingtondc-mobile/page/administer/tablet-mobile-ui/concept/mobi...