How to remove the value Response from the Messages sub tab in the service request screen for certain
Summary
Removing the value Response from the Messages sub tab for certain usersContent
Hello experts,
I need to figure out a way to remove the value Response from the Messages sub tab in the service request screen for certain users. I copied a custom role (Customer Service Representative) and removed the Compose Message privilege then I associated the custom role with a custom user and in the Server Scripts under Application Composer > Standard Objects > Service Requests > Messages > Server Scripts I added the below script but the result is that the message keeps generating for all users:
if (adf.context.getSecurityContext()?.isUserInRole('SAFWA_SVC_CUSTOMER_SERVICE_REPRESENTATIVE_JOB_CUSTOM') && ChannelTypeCd == "E-mail")
3