Fix validations in Document
Copy uploaded files to db files dir after creating document
One to many association between projects and documents

Also, store documents in projects directory.
Store CSVs of entities per document
Add link for downloading document entities CSV
Include "text" column in CSVs (human-readable form)
Do not extract pages inside a transaction

It locks the database on large documents