I want to disable Edit option on Attachment

SnehaS895807473
Tera Expert

I am trying to disable the Edit option for attachments. Please refer to the attached screenshot for reference.Earlier, there were no ACLs configured for the Transactional Product table. Therefore, I created a Delete ACL on the sys_attachment table with the following script to restrict attachment deletion:if (current.table_name == 'x_perii_mdm_work_0_transactional_product') {

var parentGR = new GlideRecord('x_perii_mdm_work_0_transactional_product');

if (parentGR.get(current.table_sys_id)) {

var recType = parentGR.getValue('record_type');

var state = parentGR.getValue('state');

if (recType == 'mdi_mdm_request' && (state == '5' || state == '6')) {

answer = false;

}

}

}

SnehaS895807473_0-1795622548260.png

 

0 REPLIES 0