Dynamic icons for impact field in the the incident table
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-04-2025 01:57 AM
So, while i am learning about scripting in ServiceNow, I was trying something. What I want is, I have three images, red.png, yellow.png and green.png. Now, I want to display one of these images based on the impact field. The change should be dynamic. I have done this using UI Macro with client script where in the Macro, I put the images and wrote an onChange client script. It is working fine. I was looking for alternative to do this only using the Macro. I found this code
This is working. So, I wanted to know if I can use all the jelly methods and functions or there are some restrictions?
Regards,
Manish Singh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-04-2025 02:05 AM
where do you wish to show the icons?
share screenshots.
Within UI macro you can use all jelly statements which are supported by ServiceNow.
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-06-2025 09:29 PM
Hi @Ankur Bawiskar,
Well I want to put those icons around the impact field.
As I have already mentioned, I did this using UI Macro, Formatter and Client Script. But the code that I have pasted is not working. The main question I have is which jelly statements can be used in ServiceNow. I would like if you can provide some documentation for jelly usage in ServiceNow.
Regards,
Manish Singh
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-06-2025 10:55 PM
you can check lot of OOTB UI macros which are added near field and that will help you know which all works
take example of this which is added to caller_id field of incident table
UI macro - user_show_incidents
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-06-2025 09:40 PM
Hi @ManishS14752344,
To learn more about Jelly, you can refer https://www.servicenow.com/docs/bundle/xanadu-api-reference/page/script/general-scripting/reference/...
Regards,
Ehab Pilloor