Skip to content

Commit

Permalink
VID-843: Improve reporting
Browse files Browse the repository at this point in the history
  • Loading branch information
Daniel Thies committed Oct 8, 2024
1 parent ebdc552 commit 9e1db50
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 3 deletions.
8 changes: 7 additions & 1 deletion lang/en/videotime.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@
<li>Enter Client ID and Client Secret <a href="{$a->configure_url}">here</a></li></ol>';
$string['confirmation'] = 'Confirmation';
$string['controls'] = 'Controls';
$string['coverage_help'] = 'Amount of video seen at least once by user';
$string['create_vimeo_app'] = 'Create Vimeo App';
$string['currentwatchtime'] = 'Current watch time';
$string['datasource:videotime_sessions_data_source'] = 'Video Time sessions';
Expand All @@ -98,6 +99,7 @@
$string['enabletabs_help'] = 'Display tabs with video which may contain additional information or interaction';
$string['estimated_request_time'] = 'Estimated time remaining';
$string['failed'] = "Failed";
$string['firstaccess_help'] = 'When user first played video';
$string['firstsession'] = 'First session';
$string['force'] = 'Force setting';
$string['force_help'] = 'If checked this default will override the instance setting.';
Expand All @@ -111,6 +113,7 @@
$string['insert_video_metadata'] = 'Insert metadata from video (may override activity settings)';
$string['invalid_session_state'] = 'Invalid session state.';
$string['label_mode'] = 'Label mode';
$string['lastaccess_help'] = 'When user last played video';
$string['lastsession'] = 'Last session';
$string['long'] = 'Long';
$string['managevideotimepluginplugins'] = 'Manage Video Time extensions';
Expand Down Expand Up @@ -285,6 +288,7 @@
$string['timeleft'] = "Time Left";
$string['timestarted'] = 'Date started';
$string['todo'] = 'TODO';
$string['totaltime_help'] = 'Time video was playing at normal speed';
$string['totaluniquevisitors'] = 'Total unique visitors';
$string['totalvideotime'] = 'Total video time: {$a->time}';
$string['totalviews'] = 'Total views';
Expand Down Expand Up @@ -316,7 +320,7 @@
$string['viewpercentgrade'] = 'Set grade equal to view percentage.';
$string['viewpercentgrade_help'] = 'Create grade item for this video. Student will receive a grade equal to their view percentage of the video.';
$string['views'] = 'Views';
$string['views_help'] = 'Number of times the activity has been viewed.';
$string['views_help'] = 'Number of separate times activity page was loaded to view video';
$string['vimeo_overview'] = 'Overview and setup';
$string['vimeo_url'] = 'Video URL';
$string['vimeo_url_help'] = 'Full URL of Vimeo video, Youtube video, or an external video or audio file.';
Expand All @@ -331,4 +335,6 @@
$string['watch_time'] = 'Watch time';
$string['watch_time_help'] = 'How long the student has watched the video in total (in 5s steps).';
$string['watchedtime'] = "Time watched";
$string['watchpercent_help'] = 'The highest percentage of the video seend';
$string['watchtime_help'] = 'The farthest position seen by the user';
$string['with_play_button'] = 'with play button';
7 changes: 7 additions & 0 deletions lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -650,6 +650,13 @@ function videotime_get_coursemodule_info($coursemodule) {
}
}

if ($instance->timeclose) {
$result->customdata['timeclose'] = $instance->timeclose;
}
if ($instance->timeopen) {
$result->customdata['timeopen'] = $instance->timeopen;
}

return $result;
}

Expand Down
9 changes: 9 additions & 0 deletions report.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
*/

use mod_videotime\videotime_instance;
use videotimeplugin_pro\output\user_report;
use videotimeplugin_pro\session;

require(__DIR__ . '/../../config.php');
Expand Down Expand Up @@ -82,6 +83,14 @@
$groupselector = '';
}

if ($userid = optional_param('userid', null, PARAM_INT)) {
$userreport = new user_report($cm, $userid);
echo $OUTPUT->header();
echo $OUTPUT->render($userreport);
echo $OUTPUT->footer();
die();
}

$table = new \videotimeplugin_pro\sessions_report_table($cm->id, $download);
$table->define_baseurl($PAGE->url);
$table->is_downloadable(true);
Expand Down
4 changes: 2 additions & 2 deletions version.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
defined('MOODLE_INTERNAL') || die();

$plugin->component = 'mod_videotime';
$plugin->release = '1.8.2';
$plugin->version = 2024050702;
$plugin->release = '1.8.3';
$plugin->version = 2024050703;
$plugin->requires = 2023042400;
$plugin->maturity = MATURITY_STABLE;

0 comments on commit 9e1db50

Please sign in to comment.