Allowing event owners use 'Manage Registrations' without 'Administer registration' permission

Created on 6 May 2015, almost 10 years ago
Updated 28 February 2025, about 1 month ago

My client's use case requires event owners (not webmaster or admin) to manage registrations through the "Manage Registrations" tab. Unfortunately, the current implementation only gives access to those with 'Administer registration' and '%reg type: Administer settings'.
To get this feature, i had to hack into the module. I changed line 135 of commerce_registration.module
from

return user_access('administer registration') || user_access("administer $registration_type registration")

to

return user_access('administer registration') || user_access("administer $registration_type registration") || node_access('update', $node);

This way, event owners who have 'Edit/update' access to the event node would also be able to see the 'Manage Registrations' tab.
Hope this helps someone.

πŸ› Bug report
Status

Closed: outdated

Component

Code

Created by

πŸ‡³πŸ‡¬Nigeria ibraaheem

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024