Notification Approval
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 09:22 PM - edited 01-15-2024 09:41 PM
Hi Community,
I have a new state specific to a catalog item. I want to hide this new state, it should only be visible to a catalog item. Once this state is selected, it should trigger an approval to a group. If approved, need to change the state of the server ci from inbuilt to active. All SC tasks attachments needs to attach on the ci selected on the form.
I have this client script to hide this new state.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 09:42 PM
Hi,
To hide this additional option only for specific cat item you need to create on Load client script.
It will hide state option as soon as form is loaded.
Use only below part in your onLoad client script.
var item = g_form.getValue('cat_item');
g_form.getValue('state');
if (item == 'a60987578739a514aa3574497bbb3533') {
g_form.removeOption('state', 5);
}
Thanks
Anil Lande
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-16-2024 01:19 AM
I have modified it to this.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-16-2024 01:23 AM
Hi Poorva,
Script is used on RITM table or some other table? Also, can you try adding alerts() at required steps to understand which of if/else condition is being satisfied.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-16-2024 01:28 AM
It is in global scope for SCtask table. I have a new dropdown option for state for a particular catalog item.