MDL-39756 add advanced attachment options to essay question type

Adds a set of options to the essay question type which implement
the following new features:

-Adds an input format which accepts only file uploads, and no
 inline text.
-Adds an option to make the inline text response optional when
 attachments are enabled, so students can choose to upload
 an essay file.
-Adds an option to make attachments required, so essays without
 attachments will be marked incomplete.
MDL-39756 fix missing form fields in essay test

[This commit will be squashed into the first MDL-39756 commit.]
MDL-39756 add defaults for the new essay type and support XML export

[This commit will be squashed into the first MDL-39756 commit.]