Disable renaming attachment

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎05-05-2016 11:17 PM
Hi, is it possible to disable the renaming of the attachment?
Because i have disabled the attachment when the request is closed. using g_form.disableAttachments();
The g_form.disableAttachments(); works but I can still rename the attachment.
Is there any way to disable that?
Here is a sample screenshot:
Thanks,
Tadz

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎07-21-2016 01:28 PM
So I managed to hack this further today, thanks to the comment from mihirtat@gmail.com above.
I also modified the attachment UI Page to
- set the value in line 83 of the HTML field to false
This tag:
<input type="hidden" id="ni.show_rename_link" name="ni.show_rename_link"
value="${jvar_can_add_attachments}" /> - set the value in line 345 of the Client script field to false
this line: var allowRename = gel('ni.show_rename_link').value;
That seems to do the trick so far but I still have to test.
EDIT: Whoops... spoke too soon. Still problematic for files uploaded via drag-and-drop method.