Access to "Add a new user" for custom role

Access to "Add a new user" for custom role

by Darrel Tenter -
Number of replies: 6

I'm trying to create a new role for "Registrar". It is not based on any Role archetype. This role should be able to create and manage user accounts, and manage course manual enrollments for users. I have the permissions working for managing course enrollments. I'm stuck on creating user accounts.

Logged in with my Registrar role I have access to the account creation page if I paste it directly.

http://site.com/course/user/editadvanced.php?id=-1

However I can't figure out how to make that page accessible via a link from the settings block. There I only have "Permissions" available under "Users". I feel I'm missing something in the role settings that gives access to "Advanced Features" where Users/Account/Add a new user is available to me as Admin.

Moodle 2.3.2 (Build: 20120910)

Average of ratings: -
In reply to Darrel Tenter

Re: Access to "Add a new user" for custom role

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

Hello there. Does Moodle's default Manager role not do what you want "out of the box"?

In reply to Mary Cooch

Re: Access to "Add a new user" for custom role

by Darrel Tenter -

Correct. If I assign Manager role to a user then login with that user, I still don't see "Add a new user". Users becoms available within Settings, but I only get Groups and Permissions. This seems to be an Admin only function. I also don't want all of the Manager capabilities for this role. Just those related to student registrations and enrollments.

In reply to Darrel Tenter

Re: Access to "Add a new user" for custom role

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

I made one of my users a manager via Settings>Site administration>users>assign system roles and when I logged in as him I did have the ability to add a new user - how have you assigned your manager?

In reply to Mary Cooch

Re: Access to "Add a new user" for custom role

by Darrel Tenter -

I go to Settings>Site Admin>Advanced features>Permissions>Assign sytem roles

I put my test user (which has no other roles assigned to it) into Existing users.

I just had a thought though and assigned the user as Site Admin, but that still didn't add anything. So something was definitely going on with the user. I edit that account and see that its Authentication method was set to Email based self registration. I changed it to Manual and voilá, I now can manage users.

Maybe it's a security thing that self-registered users cannot create user accounts. I can see the logic there. If this is true then a self-registered user being able to navigate manually to the account creation URL seems like a security hole, even if they have been assigned to a role with sufficient permissions. I also shouldn't be able to assign roles that include these permissions to self-registered accounts.

Maybe I should post this issue to the Moodle Tracker?

In reply to Darrel Tenter

Re: Access to "Add a new user" for custom role

by Mary Cooch -
Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Testers Picture of Translators

So you are saying that if a user signs up to your site with the email based self registration, if you then as admin add them as a manager or even a site admin, they are not able to add  new users? Whereas if their accounts were created manually , they are? I find that very odd - I will have to go off and test this out now and report back.

EDIT (Well  -that didn't take very long..) I went to demo.moodle,net and made a new account via email. Then I logged in as admin and made that account first a manager and then an admin and both times they were able to add users. So it is not a bug. I wonder if this is an issue with your site?

Average of ratings: Useful (1)
In reply to Mary Cooch

Re: Access to "Add a new user" for custom role

by Darrel Tenter -

Seems like that. All I did was modify the user account's registration method from email-based to manual. If I change it back to email based then permissions are lost.

I just tried to repeat at demo.moodle.net net too, and see that it works there. Looks like I have some troubleshooting to do.

Thanks for taking the time to help me with this Mary.