records: acl hook added to record documents.

* Add new model to represent documents attached to one or more records.

* Add pre hook to the default ACL to check user rights over the records
  that the document belong to.

* New record config variable `RECORD_DOCUMENT_VIEWRESTR_POLICY` to
  specify the access policy over documents attached to one or more
  records.

Signed-off-by: Esteban J. G. Gabancho <esteban.gabancho@gmail.com>