Moodle  2.2.1
http://www.collinsharper.com
enrol_manual_plugin Class Reference
Inheritance diagram for enrol_manual_plugin:
Collaboration diagram for enrol_manual_plugin:

Public Member Functions

 roles_protected ()
 allow_enrol (stdClass $instance)
 allow_unenrol (stdClass $instance)
 allow_manage (stdClass $instance)
 get_manual_enrol_link ($instance)
 add_course_navigation ($instancesnode, stdClass $instance)
 get_action_icons (stdClass $instance)
 get_newinstance_link ($courseid)
 add_default_instance ($course)
 add_instance ($course, array $fields=NULL)
 get_manual_enrol_button (course_enrolment_manager $manager)
 get_user_enrolment_actions (course_enrolment_manager $manager, $ue)
 get_bulk_operations (course_enrolment_manager $manager)

Detailed Description

Definition at line 29 of file lib.php.


Member Function Documentation

add_course_navigation ( instancesnode,
stdClass $  instance 
)

Returns enrolment instance manage link.

By defaults looks for manage.php file and tests for manage capability.

Parameters:
navigation_node$instancesnode
stdClass$instance
Returns:
moodle_url;

Reimplemented from enrol_plugin.

Definition at line 86 of file lib.php.

Here is the call graph for this function:

add_default_instance ( course)

Add new instance of enrol plugin with default settings.

Parameters:
object$course
Returns:
int id of new instance, null if can not be created

Reimplemented from enrol_plugin.

Definition at line 151 of file lib.php.

Here is the call graph for this function:

add_instance ( course,
array fields = NULL 
)

Add new instance of enrol plugin.

Parameters:
object$course
arrayinstance fields
Returns:
int id of new instance, null if can not be created

Reimplemented from enrol_plugin.

Definition at line 162 of file lib.php.

Here is the caller graph for this function:

allow_enrol ( stdClass $  instance)

Does this plugin allow manual enrolments?

Parameters:
stdClass$instancecourse enrol instance All plugins allowing this must implement 'enrol/xxx:enrol' capability
Returns:
bool - true means user with 'enrol/xxx:enrol' may enrol others freely, false means nobody may add more enrolments manually

Reimplemented from enrol_plugin.

Definition at line 36 of file lib.php.

allow_manage ( stdClass $  instance)

Does this plugin allow manual changes in user_enrolments table?

All plugins allowing this must implement 'enrol/xxx:manage' capability

Parameters:
stdClass$instancecourse enrol instance
Returns:
bool - true means it is possible to change enrol period and status in user_enrolments table

Reimplemented from enrol_plugin.

Definition at line 46 of file lib.php.

Here is the caller graph for this function:

allow_unenrol ( stdClass $  instance)

Does this plugin allow manual unenrolment of all users? All plugins allowing this must implement 'enrol/xxx:unenrol' capability

Parameters:
stdClass$instancecourse enrol instance
Returns:
bool - true means user with 'enrol/xxx:unenrol' may unenrol others freely, false means nobody may touch user_enrolments

Reimplemented from enrol_plugin.

Definition at line 41 of file lib.php.

get_action_icons ( stdClass $  instance)

Returns edit icons for the page with list of instances

Parameters:
stdClass$instance
Returns:
array

Reimplemented from enrol_plugin.

Definition at line 103 of file lib.php.

Here is the call graph for this function:

The manual plugin has several bulk operations that can be performed

Parameters:
course_enrolment_manager$manager
Returns:
array

Definition at line 283 of file lib.php.

Returns a button to manually enrol users through the manual enrolment plugin.

By default the first manual enrolment plugin instance available in the course is used. If no manual enrolment instances exist within the course then false is returned.

This function also adds a quickenrolment JS ui to the page so that users can be enrolled via AJAX.

Parameters:
course_enrolment_manager$manager
Returns:
enrol_user_button

Reimplemented from enrol_plugin.

Definition at line 185 of file lib.php.

Here is the call graph for this function:

get_manual_enrol_link ( instance)

Returns link to manual enrol UI if exists. Does the access control tests automatically.

Parameters:
object$instance
Returns:
moodle_url

Reimplemented from enrol_plugin.

Definition at line 58 of file lib.php.

Here is the call graph for this function:

Here is the caller graph for this function:

get_newinstance_link ( courseid)

Returns link to page which may be used to add new instance of enrolment plugin in course.

Parameters:
int$courseid
Returns:
moodle_url page url

Reimplemented from enrol_plugin.

Definition at line 130 of file lib.php.

Here is the call graph for this function:

Gets an array of the user enrolment actions

Parameters:
course_enrolment_manager$manager
stdClass$ueA user enrolment object
Returns:
array An array of user_enrolment_actions

Reimplemented from enrol_plugin.

Definition at line 261 of file lib.php.

Here is the call graph for this function:

Does this plugin assign protected roles are can they be manually removed?

Returns:
bool - false means anybody may tweak roles, it does not use itemid and component when assigning roles

Reimplemented from enrol_plugin.

Definition at line 31 of file lib.php.


The documentation for this class was generated from the following file:
 All Data Structures Namespaces Files Functions Variables Enumerations