Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Course module completion updated #21

Merged
merged 21 commits into from
Oct 10, 2024
Merged

Conversation

milt
Copy link
Member

@milt milt commented Oct 8, 2024

Completing/"Uncompleting" course modules. adds tests for both states. Also updates the course module object creator to set its own types.

Note that this touches a lot of stuff because the course module object creation function is (rightly) used all over the plugin.

@@ -47,10 +47,14 @@ function course_module(array $config, \stdClass $course, int $cmid, string $xapi
$courselang = utils\get_course_lang($course);
$instancename = property_exists($instance, 'name') ? $instance->name : $module->name;

$activitytype = utils\get_module_activity_type($module->name);
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is basically the biggest change here, xAPI type is decided by a single table, not whatever the caller specifies.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is where the table lives

@milt milt merged commit 5b7811c into master Oct 10, 2024
4 checks passed
@milt milt deleted the course_module_completion_updated branch October 10, 2024 15:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants