How do I prevent some users from enrolling themselves in some courses?

How do I prevent some users from enrolling themselves in some courses?

by Ted Osborne -
Number of replies: 4

I have a Moodle 2.6 site we're using in my company with a hundred or so courses and maybe a dozen categories. Users (employees) authenticate via LDAP and single sign-on (NTLM SSO) against our Active Directory server. There are currently about a thousand users. Once logged in, they're free to self-enroll in any course they like.

Now I'm trying to grant access to the site to a few non-employees (contractors). They will log in manually (they're not defined in our Active Directory system-I will configure logins for them). But I want to restrict their access to only one or two courses (or maybe only the courses in a single category). I want to prevent them from enrolling in any of the other courses on the site. (It would be even better if I could prevent them from even seeing those other course titles.)

I can't use enrollment keys because it imposes unfair friction to employees, who comprise the vast majority of users.

The conditional user fields feature looked promising, but it's too low-level (activity/resource/section). The I'd like to restrict access at the course/category level.

I'd like to avoid using anonymous "guest" access, because I'd like to offer forums/quizzes etc. to the contractors for the courses to which they have access.

Any ideas on the best way to configure contractor access to my site?

Thanks much,

Ted

Average of ratings: -
In reply to Ted Osborne

Re: How do I prevent some users from enrolling themselves in some courses?

by Kim Rushbrooke -

Hi Ted,


I found this link from Flotter Totte.

I am a newbie to moodle, and visit the moodle.org on a regular basis, and noticed this plug-in for enrolments.  Maybe it could be valuable to you, if you haven't already seen it.

https://moodle.org/mod/forum/discuss.php?d=189334

Take care

In reply to Kim Rushbrooke

Re: How do I prevent some users from enrolling themselves in some courses?

by Ted Osborne -

Thanks for the speedy reply, Kim. Sadly, I can't use that plugin for the same reason I can't use enrollment keys: it would force most of the users (1000+) to do an extra step to gain access to every course. Also, approval doesn't scale very well. We wouldn't have enough administrators to answer all the enrollment applications (if I understand the plugin correctly).

Frankly, I can't believe Moodle doesn't have a permissions capability that controls overall access to a course or a category. (Maybe it does and I haven't found it yet.) Capabilities/moodle/course:view doesn't do what one might expect (it only allows/prohibits viewing a course without enrolling). If Moodle had something like "Capabilities/moodle/course:access" or "Capabilities/moodle/category:view", I might control access through role assignments. 

Thanks again,

Ted

In reply to Ted Osborne

Re: How do I prevent some users from enrolling themselves in some courses?

by John Gifford -

Sounds to me like you want a cohorts setup...

Shouldn't be too much work, 2 cohorts and modifying the enrolment method for a hundred or so courses.

Essentially you get rid of the self-enrolment and setup cohorts of your regular users, 1 or more depending on how many different groups you want to consider e,g accounts staff can access this set of courses; warehouse staff another set etc. By the sound of it though you'd only need 1 for your regular users as they can access any course. Then you add another cohort for the external users.

With the cohorts established you use the cohort sync enrolment method and enroll the regular students into all courses while your externals can be enrolled onto selected courses. There wouldn't be any need for enrolment keys or the use of conditional access. With cohorts the user is effectively already enrolled on the course by way of their membership of the cohort, even though they haven't accessed it.

The external users would then not be able to access any course that didn't have their cohort as part of the enrolment scheme. You can even have multiple cohorts for the external users if you want a certain group of users to access a certain set of courses.

I hope this has been of some help but if you need any help please don't hesitate to let me know.

John Gifford