FMCorz/moodle-block_xp

Not possible to reward students for completing a course

Closed this issue · 4 comments

There does not seem to be a way to reward students for completing a course.

You can enter '\core\event\course_completed' as the event to catch, but due to course completion being processed by cron, the correct userid in this case is $event->relateduserid, not $event->userid, so the code never makes it through the initial background checks (in block_xp_helper::observer) and into the part that checks if the event is relevant.

Thanks for the report.

Indeed, by design the block only rewards for events which occur as the students perform actions, not when they are deferred. However, I'm working on something which should make it possible.

Hi @FMCorz, we've come across the same issue as well. Do you have any idea on when you might have an update to address it?
Many thanks!

Hopefully soon.

This feature is now available through the add-on Level up! Plus.