Flatfile enrolling and unenrolling, removing students when it shouldn't

Flatfile enrolling and unenrolling, removing students when it shouldn't

by Damon Blanchette -
Number of replies: 0

Hi!  We do flatfile enrolling and unenrolling, and we came across an interesting issue.  We have a "waitlist" role for students who have not quite made it completely into a course yet in the official sense.  With this role they can still see the course though and do things inside of it.

Once the student has gone through official channels and made it into the course, the flatfile changes to add the "student" role and remove the "waitlist" role for that student.  However, what happens is that after the "student" role is added, when "waitlist" is removed, it actually removes the student completely from the course (i.e. NO roles at all).  So instead of just removing "waitlist", the code actually removes "student" as well.

We have a workaround that pretty much works, in which we remove the "waitlist" role and then add the "student" role (we changed the order).  Still, we thought this problem might affect others - sometimes there's a case when a person has more than one role in a course, and if you want to remove just one of the multiple roles with a flatfile but keep the others, you just plain can't.  ALL of the person's roles are deleted instead of just the one you want, and they are then completely cut off from seeing the course.

edit: version is 2.3.2!

Average of ratings: -