added CHECK_PERMISSIONS to delete and patch. Also add extra parameter to permissions to include document being inserted
Merge branch 'master' of https://github.com/ld4apps/lda-serverlib into ac4ac
bug fix in delete

Delete was assuming there was a request_body available like there is for
post and patch.  This isn't the case so the document has to be retrieved
so the user's permissions to it can be checked.
changed patch check document in database not patch document
Merge remote-tracking branch 'upstream/master' into ac4ac
ignore pycharm ide files
Merge branch 'ac4ac' of https://github.com/FityFity/lda-serverlib into ac4ac
merge
Merge branch 'ac4ac'