systopia / de.systopia.resource

CiviCRM extension to specify generic resources
Other
5 stars 4 forks source link

Contact summary (entity view) fails with missing "administer CiviCRM" permission #21

Open jensschuppe opened 2 years ago

jensschuppe commented 2 years ago

Since the extension tries to add a tab to the contact summary or entity pages (e.g. for ECK entities) and therefore executes API calls without explicit permissions (and thus falling back to administer CiviCRM), when those calls fail, the exception is not caught and the entire view fails with an Authorization fails Yellow Screen of Death".

The code that adds the tabs in resource_civicrm_tabset() should be wrapped with a try-catch to avoid this.

mclwill commented 1 week ago

Any update on when this will be fixed. In my case I am looking for users with the CiviResource permission (but not 'administer CiviCRM') to be able to manage resource assignments

jensschuppe commented 1 week ago

We're currently not planning to fix it, but a PR will always be welcome (and should be easy in this case).