What is usage of RP.isRelatedList() || RP.isOneToMany() || RP.isManyToMany() in UI action buttons?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2019 12:34 AM
Hi Everyone,
I am not how to use things RP.isRelatedList() || RP.isOneToMany() || RP.isManyToMany()? what is full form RP?
Thanks,
Venkat
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2019 12:41 AM
Hi Venkat,
Pls check the below links,
How To Get Parameters/Values From a URL in ServiceNow | SN Commander
If my reply has helped you,Kindly click the Helpful button.
If my reply is the answer you were looking for, Kindly click the Accepted Solution button.
Thanks,
Priya
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2019 12:43 AM
Hi Venkat,
That is out of box I believe
check below
https://developer.servicenow.com/app.do#!/api_doc?v=london&id=RP-isInDevStudio
Mark Correct if this solves your issue and also mark Helpful if you find my response worthy based on the impact.
Thanks
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2019 12:45 AM
Hi,
1.RP.isRelatedList() - is used when a table is used as a related on other form.
2.RP.isOneTOMAny() - is being used when you want to display or hide an ui action on related list which hold the parent -child relationship
3.RP.isMantTOMany() - is being used when you want to display or hide an ui action on a m2m tables which is being used as related list
Regards,
Munender
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-13-2019 12:55 AM
Hello Venkat,
check out few points:
1.RP : is render properties.
The RenderProperties API provides methods about the current page and is available in Jelly scripts and in UI-action conditions and scripts.
Access RenderProperties methods using the static variable RP.
methods and API:
isRelatedList()
Returns true when the sys_is_related_list URL-parameter is true. Returns false if the parameter is not present.
Return:
Type Description
Boolean True if the URL parameter sys_is_related_list is true.
isManyToMany()
Returns true when the sysparm_collection_related_file URL parameter is set.
Return:
Type Description
Boolean Returns true when the sysparm_collection_related_file URL parameter is set.
For more details:
https://developer.servicenow.com/app.do#!/api_doc?v=london&id=RP-isManyToMany
Please mark as Correct Answer/Helpful, if applicable.
Thanks!
Abhishek Gardade
Abhishek Gardade