accept/reject button

nanichowdary
Giga Contributor

Hi,

We have a requirement to create accept resolution and reject buttons at form level.

--> When user clicks on the reject button, Incident state should change to Active and also he should be able to provide the comments for rejection - I created an UI action and able to change the state to active but issue is with the comments part.

--> When user clicks on the accept button, Incident state should change to Closed and form should redirect to survey page, we are using Assessment surveys - I created an UI action and able to change the state to closed but form is not redirecting to survey page.

Any help is greatly appreciable.

Thanks in Advance

Thanks

Nani

2 REPLIES 2

shloke04
Kilo Patron

You need to make the Comments field Mandatory when the Reject button is clicked. this can be achieved by using the client side control in the UI action. Please refer the link below to make the Comments field as mandate one:



Client & Server Code in One UI Action - ServiceNow Guru



For redirection you can use the below code as:




action.setRedirectURL ( 'http://www.mysite.com/mypage.htm' ) ;



Refer the below link for more details:



URL redirection using a UI action


UI Action to Redirect to a URL




Mark the response as correct/helpful based on impact.



Regards,


Shloke


Hope this helps. Please mark the answer as correct/helpful based on impact.

Regards,
Shloke

Thanks Shloke for your response.




Thanks


Nani