Suspended users and suspended user enrolments

Suspended users and suspended user enrolments

by David Monllaó -
Number of replies: 2
Hi,


We have get_enrolled_users and count_enrolled_users functions in Moodle, both functions have a $onlyactive parameter which is currently discarding suspended user enrolments, but returning/counting suspended users. $onlyactive param documentation states that consider only active enrolments in enabled plugins and time restrictions; the Suspended account user attribute help states that Suspended user accounts cannot log in or use web services, and any outgoing messages are discarded., so it seems that both suspensions have a different purpose.

I have detected a couple of curious cases:

  • Grader report - Show only active enrolments setting: Users suspended by an admin appears there even though this setting is enabled, this setting only affects enrolment suspensions
  • Assignment grading page: The same, users suspended by an admin appears in the users list, if you apply a course enrolment suspension then the user does not appear any more

I've created an issue for this (MDL-49455) I am commenting about it here to reach a bigger audience in case I am missing something and these are expected behaviours or someone has an argument about changing this behaviour so suspended users do not appear in the gradebook nor in the assign grading page (there are the two main cases I detected but there could be more). Linking the only MDocs page I've found about "suspensions" (https://docs.moodle.org/28/en/Unenrolment#Suspended_or_Unenrolled.3F) for what I understand it is considering both suspensions the same.

Thinking on a suspended user use case, an institution may be interested in suspending a user (until he pays the enrolment taxes for example) so he can not log in into the system but teachers should be able to grade the user in the meanwhile, if the enrolment is suspended for the same reason it appears there.... 

Average of ratings: -
In reply to David Monllaó

Re: Suspended users and suspended user enrolments

by John Provasnik -
Picture of Particularly helpful Moodlers Picture of Testers

I imagine the needs of the 'suspend' features would differ from organization to organization. I know there are reasons why suspending at the site level doesn't automatically suspend at the course level, and those reasons make sense.

However, I would love to see an option allowing an admin to somehow transfer the information about a site-wide suspension to the course level... Right now, I appended the user account last name with "Suspended" so the change will be noticeable by teachers in all courses the student is enrolled in.

You know how grouping an assignment will have the group name display beside it?

It would be cool if that could happen with Site-wide Suspended users when looking at their name in an assignment or graderreport. 


Average of ratings: Useful (1)
In reply to David Monllaó

Re: Suspended users and suspended user enrolments

by Melanie Scott -
Picture of Particularly helpful Moodlers
+1 You're not alone in thinking this is weird.  I've been posting about this periodically for 2+ years.  No one seems willing or able to really explain it...other than "well, that's how it works".

I'm hoping you get more responses than I have.