[minor] [fix] during reset perms, force reload doctype
[minor] [fix] clear value and run trigger of attach_files: field on removing attachment, if that attachment is being used by a given field