- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-31-2022 05:13 AM
Hi All,
I have a scenario where when there are child incidents associated with a parent incident.When teh child incident is opened,a message should be displayed "There is a parent incident INCXXX" Incident number should be a hyperlink and onclick it should open the incident on new tab.
Please suggest on how to achieve this
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-31-2022 05:56 AM
You can do this with an Display business rule, with a condition of parent incident "is not empty" and a script like this:
(function executeRule(current, previous /*null when async*/ ) {
var link = '<a href="/' + current.parent_incident.getRefRecord().getLink() + '">' + current.parent_incident.number + '</a>';
var message = 'There is a parent incident ' + link;
gs.addInfoMessage(message);
})(current, previous);
I hope this helps!
If this was helpful, or correct, please be kind and mark the answer appropriately.
Michael Jones - Proud member of the GlideFast Consulting Team!
Michael D. Jones
Proud member of the GlideFast Consulting Team!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-31-2022 05:56 AM
You can do this with an Display business rule, with a condition of parent incident "is not empty" and a script like this:
(function executeRule(current, previous /*null when async*/ ) {
var link = '<a href="/' + current.parent_incident.getRefRecord().getLink() + '">' + current.parent_incident.number + '</a>';
var message = 'There is a parent incident ' + link;
gs.addInfoMessage(message);
})(current, previous);
I hope this helps!
If this was helpful, or correct, please be kind and mark the answer appropriately.
Michael Jones - Proud member of the GlideFast Consulting Team!
Michael D. Jones
Proud member of the GlideFast Consulting Team!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎01-31-2022 06:00 AM
Sorry, minor edit - forgot to set the target in the link to open in a new tab.
(function executeRule(current, previous /*null when async*/ ) {
var link = '<a href="/' + current.parent_incident.getRefRecord().getLink() + '" target="_blank">' + current.parent_incident.number + '</a>';
var message = 'There is a parent incident ' + link;
gs.addInfoMessage(message);
})(current, previous);
I hope this helps!
If this was helpful, or correct, please be kind and mark the answer appropriately.
Michael Jones - Proud member of the GlideFast Consulting Team!
Michael D. Jones
Proud member of the GlideFast Consulting Team!