Reject Solution case
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-13-2018 07:49 AM
Hello,
i want to know if there is a way to make mandatory a comment when a customer click on reject solution button. I need because OOTB a customer can reject a CASE resolution without explaining why he is rejetcing the case resolution.
I asked some days ago here in the community, and the suggestion was "modify the UI Action as follow":
This is the script:
new global.StateFlow().processFlow(current, '05a03d27c3123100d6d210c422d3ae18', 'manual');
current.state = 'rejected';
if(!JSUtil.nil(current.comments))
current.update();
else{
gs.addErrorMessage("Comments are required when rejecting an approval");
current.state = 'requested';
current.setAbortAction(true);
}
function markclose()
{
g_form.setMandatory('comments',true);
gsftSubmit(gel('checkcomments'));
}
But, the button is still not working. No comments are mandatory if i reject case resolution.
Can you help me?
Best regards,
Lorex

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-13-2018 08:11 AM
Hi Lorex,
Try using something as below
function markclose()
{
g_form.setMandatory('comments',true);
gsftSubmit(gel('checkcomments'));
}
markingclose();
function markingclose()
{
new global.StateFlow().processFlow(current, '05a03d27c3123100d6d210c422d3ae18', 'manual');
current.state = 'rejected';
/*if(!JSUtil.nil(current.comments))
current.update();
else
{
gs.addErrorMessage("Comments are required when rejecting an approval");
current.state = 'requested';
current.setAbortAction(true);
}*/
}
Thanks,
Jaspal Singh
Hit Helpful or Correct on the impact of response.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-13-2018 08:18 AM
Still not working 😞

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-13-2018 08:31 AM
Reason being markClose() being used in onClick field & markclose() being used in Script.
Note: IT is case sensitive. Make the same for both & it should work.
Thanks,
Jaspal Singh
Hit Helpful or Correct on the impact of response.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-13-2018 08:35 AM