How to disable or remove update , delete option for attachment type field based on conditions

kalyani23
Tera Contributor

Hi 

I have a requirement where on certain conditions, I need to restrict the user from addition/updation/deletion of file in the attachment type field. or is there anyway to hide the update delete options .can someone please provide solution .

find_real_file.png

Thanks & Regards,

Kalyani

1 REPLY 1

Muhammad Hamza
Kilo Sage

Hey,

I have achieved this functionality through ACLs. You create a write ACL for that particular field. It will restrict the field to read-only. The field cannot be updated and deleted then.
I have created an ACL <Table>.<Field_Name> of operation 'write' with the condition when the Field is null. So, when the field is updated once, then it can't be deleted/updated later. Only in a record where the field is null, we can add a file there.
I am using the Tokyo version.

MuhammadHamza_0-1673421172613.png

MuhammadHamza_1-1673421195340.png

MuhammadHamza_2-1673421248280.png

MuhammadHamza_3-1673421265019.png