I don't see any course dedication tables in moodle.
Appreciate your help in this regard. Thanks in advance.
I don't see any course dedication tables in moodle.
Appreciate your help in this regard. Thanks in advance.
Hi Hema,
They are using mdl_log table to get the students total time in a course. Open the dedication_lib.php file and check the get_user_dedication() function.
Thanks
Thanks a lot for your response Nitesh.
Saw dedication_lib.php file --> get_user_dedication() function
Just wanted to understand, is there any possibility to show additional details about the user in the report.
Say for Eg: Username from mdl_user table
Try to print the $students variable before foreach loop in get_students_dedication function and check if username is in array or not.
If username is not there then use $user->id to fetch the username from DB and pass it in array like below.
$rows[] = (object) array(
'username' => $username_variable //additional
'user' => $user,
'groupid' => $group,
'dedicationtime' => $dedication,
'connectionratio' => round($daysconnected / $perioddays, 2),
);
Thanks