Added file attachment functionality to entities