(WIP) Fix/permissions for work package index

https://www.openproject.org/work_packages/10435

Need to write some tests.