diff --git a/enrol/authorize/enrol.php b/enrol/authorize/enrol.php index 7fd9bdc5da4..4ff65ca929c 100755 --- a/enrol/authorize/enrol.php +++ b/enrol/authorize/enrol.php @@ -222,7 +222,7 @@ class enrolment_plugin_authorize redirect($CFG->wwwroot, get_string("reviewnotify", "enrol_authorize"), '30'); } else { - enrol_into_course($course, $USER, 'manual'); + enrol_into_course($course, $USER, 'authorize'); redirect("$CFG->wwwroot/course/view.php?id=$course->id"); } return; @@ -255,7 +255,7 @@ class enrolment_plugin_authorize } // Credit card captured, ENROL student now... - if (enrol_into_course($course, $USER, 'manual')) { + if (enrol_into_course($course, $USER, 'authorize')) { if (!empty($CFG->enrol_mailstudents)) { send_welcome_messages($order->id); } @@ -651,7 +651,7 @@ class enrolment_plugin_authorize $timeend = $order->settletime + $course->enrolperiod; } $user = get_record('user', 'id', $order->userid); - if (role_assign($role->id, $user->id, 0, $context->id, $timestart, $timeend, 0, 'manual')) { + if (role_assign($role->id, $user->id, 0, $context->id, $timestart, $timeend, 0, 'authorize')) { $this->log .= "User($user->id) has been enrolled to course($course->id).\n"; if (!empty($CFG->enrol_mailstudents)) { $sendem[] = $order->id; diff --git a/enrol/authorize/locallib.php b/enrol/authorize/locallib.php index 648228dbcaf..17911d85611 100644 --- a/enrol/authorize/locallib.php +++ b/enrol/authorize/locallib.php @@ -279,7 +279,7 @@ function authorize_print_order_details($orderno) else { if (empty($CFG->an_test)) { $user = get_record('user', 'id', $order->userid); - if (enrol_into_course($course, $user, 'manual')) { + if (enrol_into_course($course, $user, 'authorize')) { if (!empty($CFG->enrol_mailstudents)) { send_welcome_messages($order->id); } diff --git a/enrol/authorize/uploadcsv.php b/enrol/authorize/uploadcsv.php index 98dff546e95..60719a4e2b9 100644 --- a/enrol/authorize/uploadcsv.php +++ b/enrol/authorize/uploadcsv.php @@ -206,7 +206,7 @@ function authorize_process_csv($filename) $timestart = time(); $timeend = $timestart + $course->enrolperiod; } - if (role_assign($role->id, $user->id, 0, $coursecontext->id, $timestart, $timeend, 0, 'manual')) { + if (role_assign($role->id, $user->id, 0, $coursecontext->id, $timestart, $timeend, 0, 'authorize')) { $imported++; if (!empty($CFG->enrol_mailstudents)) { $sendem[] = $order->id;