Built something you're proud of? Tell the story. A quick G2 review of App Engine or Build Agent helps other developers see what's possible on ServiceNow. Share your experience.

Catalog Item Component - "Request Generated" event is not working in Workspace

NirmalyaB
Tera Contributor

My requirement is to be able to show a popup modal with the Catalog Item form and be able to submit it from there. 

 

I have created a UI Page within the Risk BU Modals page collection. Within the page I have simply added a Catalog Item component and hardcoded the Catalog Item Sys ID. 

 

The Catalog item form is loading however, when I click on the "Order Now" button nothing happens and it stays disabled. I added an event handler for the "Request generated" event so it closes the modal post submission. However it seems to be not working i.e. no Requests/Requested Items are created.

 

I also added a handler for the "Item Submission cancelled" event, which seems to be working fine, wherein I was able to close the modal with the help of a Client Script. 

 

I tried applying the same Client Script handler to the "Request Generated" event, but again with no success. 

 

NirmalyaB_0-1777364260969.png

NirmalyaB_1-1777364286682.pngNirmalyaB_2-1777364312029.png

 

1 REPLY 1

Maham Tahir
Mega Guru

Hi @NirmalyaB

 

This issue occurs cuz Catalog Item component in UI Builder (Workspace) requires a Data Resource to handle the actual submission logic, component itself is just the UI layer.

 

The "Order Now" button won't process unless it's linked to a submission action.

  • In UI Builder, add the "Submit Catalog Item" Data Resource to your page.

  • Ensure the sys_id in the Data Resource matches the Catalog Item you are showing.

If you find my response helpful, mark it as helpful and accepted solution.

 

Regards, 

Maham Tahir.