Browse Source

New: Events in Moodle 2.7

MOODLE_20_STABLE
Vasilis Daloukas 11 years ago
parent
commit
6d5c6a378b
  1. 4
      version.php
  2. 6
      view.php

4
version.php

@ -11,7 +11,7 @@
defined('MOODLE_INTERNAL') || die();
$module->component = 'mod_game'; // Full name of the plugin (used for diagnostics)
$module->version = 2014061002; // The current module version (Date: YYYYMMDDXX)
$module->version = 2014061003; // The current module version (Date: YYYYMMDDXX)
$module->requires = 2010112400; // Requires Moodle 2.0
$module->cron = 0; // Period for cron to check this module (secs)
$module->release = '3.18.10.2';
$module->release = '3.18.10.3';

6
view.php

@ -46,8 +46,12 @@
$canattempt = true;
}
/// Log this request.
if( game_use_events())
{
require( 'classes/event/course_module_viewed.php');
\mod_game\event\course_module_viewed::viewed($game, $context)->trigger();
}else
add_to_log($course->id, 'game', 'view', "view.php?id=$cm->id", $game->id, $cm->id);
// Mark as viewed

Loading…
Cancel
Save