Disabling the Submit / Order Now button in Service portal of the Catalog item
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-25-2019 03:45 AM
Hi All ,
I have requirement , based on the variable value i.e Yes/ No , the Submit / Order now button should be disabled.
If the value is 'No', the button should be disabled .
Can any please help in this .
Thanks ,
Navyaa
- Labels:
-
Service Catalog
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-25-2019 03:50 AM
Write onSubmit catalog client script,
if(g_form.getValue("variable_name")=='yes'){
return true;
}else{
return false;
}
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-29-2019 01:23 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-29-2019 01:37 AM
HI,
try yo this code:
If this is a submit button that would be seen from a Record Producer or Catalog Item, you could disable the Submit button using an onSubmit Catalog Client Script in the Record Producer/Catalog Item.
Ensure that the onSubmit Catalog Client Script has a UI Type of "Both", add in your conditional criteria for when you would want to disable the Submit button, and end that conditional criteria with "return false;" For instance:
function onSubmit() {
if (g_form.getValue('subcategory') == 'DisableSubmit') {
var message = '';
message = message + 'Submit is disabled for the specific subcategory' + '\n' + '\n';
alert(message);
return false;
}
}
I hope that this helps,

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-29-2019 01:39 AM
Hi,
also, try this:
Go to system UI->Messages->search for "Order Now"->Replace message with "Submit" and save.
check this link you find some interesting information related :
Please mark answer as correct if this answers your question.