[ Index ]

PHP Cross Reference of moodle-2.8

title

Body

[close]

/completion/criteria/ -> completion_criteria_activity.php (summary)

This file contains the activity completion criteria type class and any supporting functions it may require.

Author: Aaron Barnes <[email protected]>
Copyright: 2009 Catalyst IT Ltd
License: http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later
File Size: 285 lines (9 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

completion_criteria_activity:: (11 methods):
  fetch()
  config_form_display()
  update_config()
  get_mod_name()
  get_mod_instance()
  review()
  get_title()
  get_title_detailed()
  get_type_title()
  cron()
  get_details()


Class: completion_criteria_activity  - X-Ref

Course completion critieria - completion on activity completion

fetch($params)   X-Ref
Finds and returns a data_object instance based on params.

param: array $params associative arrays varname=>value
return: completion_criteria_activity data_object instance or false if none found.

config_form_display(&$mform, $data = null)   X-Ref
Add appropriate form elements to the critieria form

param: moodleform $mform  Moodle forms object
param: stdClass $data details of various modules

update_config(&$data)   X-Ref
Update the criteria information stored in the database

param: stdClass $data Form data

get_mod_name($type)   X-Ref
Get module instance module type

param: int $type Module type id
return: string

get_mod_instance()   X-Ref
Gets the module instance from the database and returns it.
If no module instance exists this function returns false.

return: stdClass|bool

review($completion, $mark = true)   X-Ref
Review this criteria and decide if the user has completed

param: completion_completion $completion     The user's completion record
param: bool $mark Optionally set false to not save changes to database
return: bool

get_title()   X-Ref
Return criteria title for display in reports

return: string

get_title_detailed()   X-Ref
Return a more detailed criteria title for display in reports

return: string

get_type_title()   X-Ref
Return criteria type title for display in reports

return: string

cron()   X-Ref
Find users who have completed this criteria and mark them accordingly


get_details($completion)   X-Ref
Return criteria progress details for display in reports

param: completion_completion $completion The user's completion record
return: array An array with the following keys:



Generated: Fri Nov 28 20:29:05 2014 Cross-referenced by PHPXref 0.7.1