Redirect to new catalog item onsubmit


If there is a requirement to open another catalog item on-submit based on the selection of field value in the current catalog item, then we cannot open the new item on the same tab of the browser. Onsubmit performs the Service Catalog API to insert a record on server side and return to checkout page to show the request details. So a new item on submit can be called on the new tab of the browser


As an example: In a Platform, to open a catalog item 'ABC Test item' in a new tab on-submitting the existing catalog item 'XYZ Test item'

Example: Create an onsubmit catalog client script of the 'XYZ Test item' catalog item having field 'IP type' with values 'static' and 'dynamic'. On selecting 'dynamic', 'ABC TEST' catalog item to open on submission.

Result: 'ABC Test item' catalog item opens in a new tab and existing tab has active transaction of 'XYZ Test item' catalog item to show the checkout page of request submitted.

var gr = g_form.getValue('ip_type');

if (gr == 'dynamic')

{'/<sysID of 'ABC Test Item' catalog Item>','_blank');