A quick question regarding permissions:

On my site, Role "A" has all the Registrations permissions and is able to fully manage an event's registrations on the Manage Registrations tab. I would like another group of users, Role "B" to be able to see all registrations in the Manage Registration tab but not be able to edit/delete them.

How would I set up Role "B"'s permissions? No matter what I try, I can't get exactly this functionality to work.

Thanks.

Comments

hellomobe’s picture

I think you can enable permission for Role B as follows:

1. ERType: Administer setting - this is all nodes with ER type
2. ERType: Administer own settings - this is only on nodes that the user created.

Role B should be able to view, delete, or edit the registration entity (they will just be able to see the table).

ksignorini’s picture

Priority: Normal » Critical

This still isn't working.

I've done some fairly exhaustive testing and this is what I've found:

"ERType: Administer own settings" - ** this is behaving just like "ERType: Administer settings" -- that is, regardless of which user created the registration if I assign this setting to Role B then Role B can see the Manage Registrations tab (Registrations list) on any content with a Registration as well as use the "Settings" link/page for the registration and use the "Email Registrants" link/page for that registration. What they can't do is use the View, Edit, or Delete links (although the links are still visible).

I still cannot seem to get the following to work, no matter what settings are chosen in permissions:

1. Role A can fully manage registrations for ERType, including use of Manage Registrations tab, Registrations list, Settings link/page, Email Registrations link/page, and View, Edit, Delete links for individual registrations.
2. Role B can perform the exact same tasks as in 1. above but only for content they've created.
3. Role B can view the Manage Registrations tab and Registrations list on that tab, but has no other "management" tasks available (i.e. cannot edit Settings, Email Registrants, or View, Edit, Delete registrations).

(This seems like a bug at this point. I've changed Priority for this issue to Critical as it's a permissions issue.)

utaren’s picture

I have exactly the same problem. No matter how i set the permissions, either there is only full viewing/editing/deleting of registrations or nothing is possible.

Couple of minutes later: I found this code in registration\modules\registration_views\includes\registration_handler_field_registration_link_delete.inc:

/**
 * @file
 * Field handler to render a link to delete a registration.
 */
class registration_handler_field_registration_link_delete extends registration_handler_field_registration_link {

  /**
   * Renders the link.
   */
  function render_link($entity, $values) {
    // Ensure user has access to delete this registration.
    if (!entity_access('delete', 'registration', $entity)) {
      return;
    }

    $this->options['alter']['make_link'] = TRUE;
    $this->options['alter']['path'] = "registration/{$entity->registration_id}/delete";
    $this->options['alter']['query'] = drupal_get_destination();

    $text = !empty($this->options['text']) ? $this->options['text'] : t('delete');
    return $text;
  }
}

Why this code is not working? I am not familiar with programming, any help would be appreciated!

GWartena’s picture

Issue summary: View changes

I have the same issue. I also want users with a certain role only to see the list of registrations, but this does not seem to work...

GWartena’s picture

Issue summary: View changes
john.oltman’s picture

Status: Active » Closed (outdated)