Search moodle.org's
Developer Documentation

See Release Notes

  • Bug fixes for general core bugs in 4.3.x will end 7 October 2024 (12 months).
  • Bug fixes for security issues in 4.3.x will end 21 April 2025 (18 months).
  • PHP version: minimum PHP 8.0.0 Note: minimum PHP version has increased since Moodle 4.1. PHP 8.2.x is supported too.

(no description)

File Size: 157 lines (7 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

activity_completion:: (5 methods):
  __construct()
  export_for_template()
  get_overrideby()
  get_completion_details()
  get_accessible_description()


Class: activity_completion  - X-Ref

The activity completion renderable class.

__construct(protected cm_info $cminfo,protected cm_completion_details $cmcompletion)   X-Ref
Constructor.

param: cm_info $cminfo The course module information.
param: cm_completion_details $cmcompletion The course module information.

export_for_template(renderer_base $output)   X-Ref
Export this data so it can be used as the context for a mustache template.

param: renderer_base $output Renderer base.
return: stdClass

get_overrideby()   X-Ref
Returns the name of the user overriding the completion condition, if available.

return: string

get_completion_details($overrideby)   X-Ref
Returns automatic completion details

param: string $overrideby The name of the user overriding the completion condition, if available.
return: array

get_accessible_description($overrideby, $overallcompletion)   X-Ref
Returns the accessible description for manual completions with overridden completion state.

param: string $overrideby The name of the user overriding the completion condition, if available.
param: int $overallcompletion The overall completion state of the activity.
return: string