Find your people. Pick a challenge. Ship something real. The CreatorCon Hackathon is coming to the Community Pavilion for one epic night. Every skill level, every role welcome. Join us on May 5th and learn more here.

Incident Related Link to Catalog Item – Conditional Display Based on Assignment Group Parent and Gro

LokeshwarRV
Tera Contributor

Hi Community,

I’m looking for guidance on configuring a Related Link on the Incident form with specific visibility conditions.

Requirement

LokeshwarRV_0-1767967905336.png

 

I want to add a Related Link on the Incident form called:

Hardware Refresh Request

This Related Link should:

  1. Open a specific Catalog Item (hardware refresh request form).
  2. Only be visible when:
    • The Incident’s Assignment Group parent is either:
      • Global Field Support, or
      • Regional Field Support
    • AND the logged‑in user is a member of the Incident’s Assignment Group.

Additional Notes

  • The Related Link should not appear if either condition is not met.
  • The catalog item can open in either Service Portal or Classic UI.
1 ACCEPTED SOLUTION

@LokeshwarRV 

Hope you are doing good.

Did my reply answer your question?

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

View solution in original post

2 REPLIES 2

Ankur Bawiskar
Tera Patron

@LokeshwarRV 

something like this in UI action condition and script

gs.getUser().isMemberOf(current.assignment_group) && (current.assignment_group.parent == 'Global Field Support' || current.assignment_group.parent == 'Regional Field Support')

Client Checkbox - true

Onclick - hardwareRefreshCatalog()

UI action script

function hardwareRefreshCatalog() {
    var catalogItemSysId = 'YOUR_CATALOG_ITEM_SYS_ID';
    var incidentNumber = g_form.getUniqueValue(); // Pass incident number as parameter

    // Service Portal (Recommended)
    window.open('/sp?id=sc_cat_item&sys_id=' + catalogItemSysId + '&sysparm_incident=' + incidentNumber, '_blank');

    // OR Classic UI
    // window.open('/nav_to.do?uri=sc_cat_item.do?sys_id=' + catalogItemSysId, '_blank');
}

AnkurBawiskar_0-1767969778061.png

 

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

@LokeshwarRV 

Hope you are doing good.

Did my reply answer your question?

💡 If my response helped, please mark it as correct and close the thread 🔒— this helps future readers find the solution faster! 🙏

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader