The CreatorCon Call for Content is officially open! Get started here.

Remove the Create New button from Incident Task if Incident is assigned to a specific group

Cupcake
Mega Guru

If someone can provide any assistance I would be most appreciative.

I have a customer who wants the "Create New" button removed from the Incident task if the Incident is assigned to a specific group.

If the Incident is not assigned to that group then the Create New button should be there.

Not sure if this needs to be accomplished via a Business Rule or Client Script.

So I see that I would need to update this in two places.

a) Directly remove the Create Inc task button from the Incident if the Incident is assigned to a specific group:

        find_real_file.png

b) Remove the New button directly on the Incident Task.

find_real_file.png

Thanks,

Karen

19 REPLIES 19

harmangill02
Mega Expert

Karen,



You will need to create a "write" ACL on the "Incident Tasks" and write an if statement that returns the answer = true, if the user doesn't belong to that group. That should restrict write access to the table for the specific group and they won't see the "New" button in the related list and also won't have permissions to create a INC task directly from the table.


Hi Harman I did a write and a create ACL with the script as follows and it is still allowing a user that is not a part of that assignment group to write


find_real_file.png


Andras Kisgyorg
Kilo Guru

Hi Karen,



I would consider setting up an ACL to control the "create" access in that case under these conditions.



Please check if the below fits your requirement:


ACL with type = record, operation = create on incident_task table,


and the condition could be incident.assignment_group (you should be able to dot-walk up to assignment group field by selecting Incident field first and then related fields at the bottom of the picker) to get to Incident.assignment_group IS NOT (the group in your case) condition.



You may specify other conditions which need to evaluate to true to give access to creation.



Also, check for other ACLs which are created on incident_task table to ensure there is no other ACL which may allow create operation on incident_task table.



Please let me know if this helped.



Best regards,


Andras


Hi Andras,


      I created the "Create" ACL as such, but it doesn't seem to be working. I impersonated someone that is not a member of that assignment group to create a new incident task. I also create a write ACL with the same script in it as Harman Gill suggested.



Not sure what is going on.



find_real_file.png



Thanks,


Karen