Assign Student Role (Site Wide) Question

Assign Student Role (Site Wide) Question

by Aaron Souza -
Number of replies: 7

Hello all,

Because I can get long winded, I will start with a summary of what I want to do.

I want to automatically assign accounts as students (site context) so I can start locking down what students cannot do. Currently we do not use ldap or any other real user database, so I generate student accounts with the upload users function.

Can I just add something in the list for each account to the effect of: site-context = student ?



------- Longer Version ----------
After a successful pilot test of Moodle, we are moving it into a real test environment (outside access etc).

I can easily create a bunch of students with the upload users function, but I don't know how to assign then as 'site students'? I want this functionality because I need to have certain things locked down for our students (K-8th grade). For example, I do not want kids managing their own calendar, blogging or changing their profile. I've managed to lock down the blogging and changing profiles with a little php code I found someone posted here, but for using the calendar - I can only stop that with the defining student roles at the main admin page.

When I create these accounts, they are essentially 'in limbo' and just enroll when we tell them the password. But when you click on 'Assign Roles' in the main administration site, there is only the handful of accounts labeled as students that I manually dragged over.

p.s. If assigning all students to the 'site context student' roll is a bad idea, please let me know (although I assume its not).


Thanks in advance,
Aaron
Attempting to bring Moodle to a K-8 environment.

Average of ratings: -
In reply to Aaron Souza

Re: Assign Student Role (Site Wide) Question

by Helen Foster -
Picture of Core developers Picture of Documentation writers Picture of Moodle HQ Picture of Particularly helpful Moodlers Picture of Plugin developers Picture of Testers Picture of Translators
Hi Aaron,

You may restrict what students can/cannot do by editing the Student role via the Manage roles tab in Administration > Users > Permissions > Define roles.

You should only assign students in the site/system context if you want them to have the role of student site-wide i.e. to be enrolled on every course. Is this what you want?
In reply to Helen Foster

Re: Assign Student Role (Site Wide) Question

by Aaron Souza -

No its not... For whatever reason though- it seemed that the only way I could control the policies was if I put the students in the site-wide student context?  (i.e. preventing students from using calendar, mass-messaging, etc.)

When I was testing, I would disable say, calendar, but it would only 'apply' if my test student account was in the site-wide context.

Also, can't I just put entrollment keys on all my classes, that way even if you are a 'side wide student' I won't have problems with you messing in other classes?  I want all my students to be students, and nothing higher. I just don't want them going also into other classes (enrolment keys should stop that?)

Aaron

In reply to Aaron Souza

Re: Assign Student Role (Site Wide) Question

by Yu Zhang -
Hi Aaron,

By assigned students at the system context you are actually making them students for all courses. Enrolment key will not be able to prevent them from entering courses.

Cheers,

Yu
In reply to Helen Foster

Re: Assign Student Role (Site Wide) Question

by Samuli Karevaara -

"You should only assign students in the site/system context if you want them to have the role of student site-wide i.e. to be enrolled on every course."

I'm echoing myself, but is there a way then to have users automatically as students on the front page without the "enrolled everywhere" side effect?

In reply to Samuli Karevaara

Re: Assign Student Role (Site Wide) Question

by Yu Zhang -
Hi Samuli,

This is not possible in 1.7, we split system context and site context in 1.8, so system context is the top node of the roles hierarchy, and site context is the front page course. If you assign students to the site context in 1.8, there will be no "enrolled" everywhere effect.

Cheers,

Yu


In reply to Yu Zhang

Re: Assign Student Role (Site Wide) Question

by Samuli Karevaara -
Ok, thanks for the clarification. We already decided to skip 1.7 and go for 1.8, and this is one more justification to the decision. (Though I'm still wondering if 1.8 is behaving a bit differently than 1.6 with allusersaresitestudents=true...)
In reply to Yu Zhang

Re: Assign Student Role (Site Wide) Question

by Jamie Pratt -

Hi Yu!


Does this mean that the info on the context hierarchy in the wiki is wrong (see below)?

Do the items marked as having parent site actually have parents system now in 1.8?? And so the student role in the site context is not inherited by course categories / courses / activities?

Jamie

The list of contexts in hierarchical order is as follows:

  • System context - accessible via the administrator's block (no parent)
  • Site context - accessible via the administrator's block front page section (parent = system) 1.8+ only
  • Course category context - accessible via the course category page (parent = site)
  • Course context - accessible via the course administration block (old admin block) (parent = course category or site)
  • Module context - accessible whilst updating the module (parent = course)
  • Block context - accessible when editing mode is on (parent = site or course)
  • User context - accessible via the Roles tab in the user profile (parent = site)