Push message redirection for mobile web screen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-13-2022 08:58 AM
All,
I have added Connect Chat quick action to our Now Mobile App and successfully implemented a push notification for it. Once the notification is received when I tap on it, I expect to be taken to the conversation in the connect screen. This happens successfully, except that it always lands up with the conversation screen that was last visited even if there is a new conversation with a different profile.
Not sure how to make the URL of the mobile web screen accept the record sys_id from the Push Message content of the notification dynamically each time.
Code segment of the connect screen of type 'mobile web screen' is as below:
id = current.group.toString();
gs.info("**********" + id);
link = deepLinkGenerator.getFormScreenLink("95bf864b1b70411069770d82604bcb19", 'live_message', id);
The url in the 'mobile web screen' is:
/$c.do?uri=chat&sys_id=id
Any idea how to get this to work properly? I have searched the community and the documents but didn't find an answer.
Thanks!
- Labels:
-
Mobile app configuration
-
Now Mobile
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-13-2022 10:48 AM
Have you checked if the previous conversation is UNFOLLOWED or not .
For example , I want to receive an update related to incident then I can click on Follow button that I see on Incident header. So , until I press Unfollow or click the Follow again to discontinue I will keep on receiving messages of that incident iny conversation chat of Connect , once I unfollow it I won't be receiving any further updates with respect to that and then whenever any new conversation starts you will see clear or new screen .
For more information about what I am saying with respect to Follow check this link : https://docs.servicenow.com/bundle/rome-servicenow-platform/page/use/collaboration/concept/c_CollaborationAdministration.html
Mark my Answer as Correct and Helpful if it helps
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-13-2022 11:35 AM
Thanks for your reply. I am not talking about following any record. Just a simple chat with user A followed by a chat with user B lands up always showing the user A's conversation screen when redirected from the push message. The URL of the mobile web screen is not getting updated with the id from the deep link generator in the push message content.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-16-2022 12:49 AM
In your webscreen it should be enough to write {{sys_id}}, so it should be :
/$c.do?uri=chat&sys_id={{sys_id}}
And make sure to have Relative URL to true!
Best regards,
Sebastian Laursen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-18-2022 08:15 AM
Thanks for the reply. I tried your solution but it did not even land on the connect screen. Instead got the alert "Invalid URL". However, if instead of sys_id={{sys_id}}, I use sys_id=id, it works by redirecting to the connect conversation screen, but the original issue remains. Which is, if after receiving from user-A and checking the conversation I receive notification from user-B, I am redirected back to User-A's conversation instead of User-B's