diff --git a/2.4/blocks/aspirelists/version.php b/2.4/blocks/aspirelists/version.php index a2e08db..4016efb 100644 --- a/2.4/blocks/aspirelists/version.php +++ b/2.4/blocks/aspirelists/version.php @@ -4,6 +4,6 @@ defined('MOODLE_INTERNAL') || die(); -$plugin->version = 201803081830; // YYYYMMDDHHMM (year, month, day, 24-hr time) +$plugin->version = 201805291000; // YYYYMMDDHHMM (year, month, day, 24-hr time) $plugin->requires = 2012120300; // YYYYMMDDHH (This is the release version for Moodle 2.4) $plugin->component = 'block_aspirelists'; \ No newline at end of file diff --git a/2.x-activity-module/mod/aspirelists/db/upgrade.php b/2.x-activity-module/mod/aspirelists/db/upgrade.php index 28f9a39..80d8a52 100644 --- a/2.x-activity-module/mod/aspirelists/db/upgrade.php +++ b/2.x-activity-module/mod/aspirelists/db/upgrade.php @@ -131,4 +131,8 @@ function xmldb_aspirelists_upgrade($oldversion) { upgrade_mod_savepoint(true, 2017070400, 'aspirelists'); } + if ($oldversion < 201805291000){ + upgrade_mod_savepoint(true, 201805291000, 'aspirelists'); + } + } \ No newline at end of file diff --git a/2.x-activity-module/mod/aspirelists/launch.php b/2.x-activity-module/mod/aspirelists/launch.php index 4966bc7..983fd59 100644 --- a/2.x-activity-module/mod/aspirelists/launch.php +++ b/2.x-activity-module/mod/aspirelists/launch.php @@ -18,6 +18,11 @@ $course = $DB->get_record('course', array('id' => $cm->course), '*', MUST_EXIST); $context = context_module::instance($cm->id); +if($CFG->version >= 2017111300) { + $PAGE->set_cm($cm, $course); // set up global $COURSE +} + +// Log the launch if($CFG->version < 2014051200) { add_to_log($course->id, "aspirelists", "launch", "launch.php?id=$cm->id", "$list->id"); } else { @@ -32,6 +37,7 @@ $event->trigger(); } +// Perform the launch $list->cmid = $cm->id; aspirelists_add_lti_properties($list); if($CFG->version >= 2015111600) {