Service Portal / Incident - Stop users from adding comments on Closed / Cancelled Tickets

arnabbose
Tera Expert

Hello,

I want to Stop users from adding comments on Closed / Cancelled Incident Tickets (basically inactive tickets) from Service Portal. How can I do that in the most easy way?

find_real_file.png

10 REPLIES 10

Mike Patel
Tera Sage

On your Ticket Conversation widget find HTML Template line (32)

<form ng-submit="postEntry(data.journalEntry)" id="sand">

change it to

<form ng-if="data.active" ng-submit="postEntry(data.journalEntry)" id="sand">

 

and add to Server script after 

gr.get(data.sys_id);
if (!gr.canRead())
return;

data.active = gr.getDisplayValue('active') === "true";

That was extremely helpful Mike, thank you for sharing this.

Hello Mike,

 

I've tried this and it worked partially...

Initially , the comments section is enabled for all the states. We've checked in widget configuration and modified the html script. From then, the comments section is disabled for all the states. Could you please help me further .. Thanks!!

arnabbose
Tera Expert

Hi Mike,

I added the lines you mentioned, But still able to make comments from Service Portal.

find_real_file.png

 

find_real_file.png