Hi,
I tried to configure MNet and get remote enrollments work, but when i enroll an user in two courses of the same host(peer) it deletes the record of the previous course enrolled in that host.
Delete record is on mdl_mnetservice_enrol_enrolments.
I made an slight debug on the php files and was able to get one line (signed with an arrow by me).
The file is /mnet/service/enrol/locallib.php, function req_course_enrolments.
// prune stale enrolment records
if (empty($list)) {
$DB->delete_records('mnetservice_enrol_enrolments', array('hostid'=>$mnethostid));
} else {
list($isql, $params) = $DB->get_in_or_equal(array_keys($list), SQL_PARAMS_NAMED, 'param0000', false);
$params['hostid'] = $mnethostid;
$select = "hostid = :hostid AND id $isql";
-> $DB->delete_records_select('mnetservice_enrol_enrolments', $select, $params);
}
I get this by debug the /mnet/service/enrol/course.php file.
If i comment this line, everything works fine, but i wish to know detailed information about this line, to know the problems that i can get if i comment it.
If someone have more information about it, TIA.
Best regards,
Pedro Galvão