|
Moodle
2.2.1
http://www.collinsharper.com
|
Go to the source code of this file.
| enum LESSON_CLUSTERJUMP |
Cluster Jump
Definition at line 55 of file locallib.php.
| enum LESSON_EOL |
End of Lesson
Definition at line 45 of file locallib.php.
LESSON_MAX_EVENT_LENGTH = 432000 ; 5 days maximum
Definition at line 60 of file locallib.php.
| enum LESSON_NEXTPAGE |
Jump to Next Page
Definition at line 43 of file locallib.php.
| enum LESSON_PREVIOUSPAGE |
Jump to Previous Page
Definition at line 49 of file locallib.php.
| enum LESSON_RANDOMBRANCH |
Jump to a random Branch
Definition at line 53 of file locallib.php.
| enum LESSON_RANDOMPAGE |
Jump to a random page within a branch and end of branch or end of lesson
Definition at line 51 of file locallib.php.
| enum LESSON_THISPAGE |
Include the files that are required by this module This page
Definition at line 37 of file locallib.php.
Next page -> any page not answered correctly
Definition at line 41 of file locallib.php.
| enum LESSON_UNDEFINED |
Undefined
Definition at line 57 of file locallib.php.
Jump to an unseen page within a branch and end of branch or end of lesson
Definition at line 47 of file locallib.php.
| enum LESSON_UNSEENPAGE |
Next page -> any page not seen before
Definition at line 39 of file locallib.php.
| lesson_add_fake_blocks | ( | $ | page, |
| $ | cm, | ||
| $ | lesson, | ||
| $ | timer = null |
||
| ) |
| $cm | |
| $lesson | |
| $page |
Definition at line 418 of file locallib.php.

| lesson_add_header_buttons | ( | $ | cm, |
| $ | context, | ||
| $ | extraeditbuttons = false, |
||
| $ | lessonpageid = null |
||
| ) |
Adds header buttons to the page for the lesson
| object | $cm | |
| object | $context | |
| bool | $extraeditbuttons | |
| int | $lessonpageid |
Definition at line 570 of file locallib.php.


| lesson_clock_block_contents | ( | $ | cmid, |
| $ | lesson, | ||
| $ | timer, | ||
| $ | page | ||
| ) |
If a timed lesson and not a teacher, then return a block_contents containing the clock.
| int | $cmid | Course Module ID for this lesson |
| object | $lesson | Full lesson record object |
| object | $timer | Full timer record object |
Definition at line 484 of file locallib.php.


| lesson_display_teacher_warning | ( | $ | lesson | ) |
Any other lesson functions go here. Each of them must have a name that starts with lesson_ Checks to see if a LESSON_CLUSTERJUMP or a LESSON_UNSEENBRANCHPAGE is used in a lesson.
This function is only executed when a teacher is checking the navigation for a lesson.
| stdClass | $lesson | Id of the lesson that is to be checked. |
Definition at line 77 of file locallib.php.
| lesson_displayleftif | ( | $ | lesson | ) |
Determines if a user can view the left menu. The determining factor is whether a user has a grade greater than or equal to the lesson setting of displayleftif
| object | $lesson | Lesson object of the current lesson |
Definition at line 392 of file locallib.php.
| lesson_get_media_html | ( | $ | lesson, |
| $ | context | ||
| ) |
This is a function used to detect media types and generate html code.
object $CFG object $PAGE
| object | $lesson | |
| object | $context |
Definition at line 592 of file locallib.php.

| lesson_grade | ( | $ | lesson, |
| $ | ntries, | ||
| $ | userid = 0 |
||
| ) |
Calculates a user's grade for a lesson.
| object | $lesson | The lesson that the user is taking. |
| int | $retries | The attempt number. |
| int | $userid | Id of the user (optional, default current user). |
Definition at line 274 of file locallib.php.


| lesson_mediafile_block_contents | ( | $ | cmid, |
| $ | lesson | ||
| ) |
If there is a media file associated with this lesson, return a block_contents that displays it.
| int | $cmid | Course Module ID for this lesson |
| object | $lesson | Full lesson record object |
Definition at line 447 of file locallib.php.

| lesson_menu_block_contents | ( | $ | cmid, |
| $ | lesson | ||
| ) |
If left menu is turned on, then this will print the menu in a block
| int | $cmid | Course Module ID for this lesson |
| lesson | $lesson | Full lesson record object |
Definition at line 516 of file locallib.php.


| lesson_random_question_jump | ( | $ | lesson, |
| $ | pageid | ||
| ) |
Handles the random jump between a branch table and end of branch or end of lesson (LESSON_RANDOMPAGE).
| lesson | $lesson | |
| int | $pageid | The id of the page that we are jumping from (?) |
Definition at line 231 of file locallib.php.


| lesson_unseen_branch_jump | ( | $ | lesson, |
| $ | userid | ||
| ) |
Handles the unseen branch table jump.
| lesson | $lesson | |
| int | $userid | User id. |
Definition at line 174 of file locallib.php.


| lesson_unseen_question_jump | ( | $ | lesson, |
| $ | user, | ||
| $ | pageid | ||
| ) |
Interprets the LESSON_UNSEENBRANCHPAGE jump.
will return the pageid of a random unseen page that is within a branch
| lesson | $lesson | |
| int | $userid | Id of the user. |
| int | $pageid | Id of the page from which we are jumping. |
Definition at line 107 of file locallib.php.
