Hiding email client icon/button for Closed Incidents

ramwons
Kilo Expert

Hello,

I want to hide the email client icon/button for the closed incidents only. is it possible?. If yes how can I achieve it.

Thanks,

Ram

1 ACCEPTED SOLUTION

AbhishekGardade
Giga Sage

Hello ram,

Create onLoad Client script as below :

find_real_file.png

 

function onLoad() {
//Type appropriate comment here, and begin script below
var incState = g_form.getValue('incident_state');

if(incState == '7') // 7 is value for closed
{
$('email_client_open').hide();
}
}

Make sure that ISOLATED SCRIPT is UNCHECKED.
New client-scripts are run in strict mode, with direct DOM access disabled. Access to jQuery, prototype and the window object are likewise disabled. To disable this on a per-script basis, configure this form and add the "Isolate script" field. To disable this feature for all new globally-scoped client-side scripts set the system property "glide.script.block.client.globals" to false.

Please mark as Correct Answer and Helpful, if applicable.
Thanks!
Abhishek Gardade
Hexaware Technologies

Thank you,
Abhishek Gardade

View solution in original post

5 REPLIES 5

Thanks Abhishek.