Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WR422914 Subplugin refactor #161

Open
wants to merge 1 commit into
base: MOODLE_400_STABLE
Choose a base branch
from
Open

Conversation

SimonThornett
Copy link

Taken from the README.md:

Post version 2024040300 this plugin was completely refactored to support more reports and modules.
In addition the report now loads in a tabbed format instead of in different locations.

Each report is now a subplugin within the report directory
The subplugins report class should extend from the \local_assessfreq\report_base class

Capability checks were reworked to be relative to the location that they are being loading from. The initial version
has the following capabilities:

  • local/assessfreq:view
  • assessfreqreport/activity_dashboard:view
  • assessfreqreport/activities_in_progress:view
  • assessfreqreport/heatmap:view
  • assessfreqreport/summary_graphs:view

however each future subplugin can define their own access checks by using the abstract has_access method.
Accessing the reports from a course (link now added to the course context menu under reports) will do the capability check at the
course context level, otherwise system level will be used.

The reports themselves should also be restricted based on the $PAGE->course if it is not the SITEID as this is set
during the intial load of the index.php file.

Each module is now a subplugin within the source directory
The subplugins source class should extend from the \local_assessfreq\source_base class

Complete refactor of the plugin to move reports and modules into
report and source subplugins respectively.
@dmitriim
Copy link
Member

Hi @SimonThornett
Very exciting changes. However, can you please apply the changes to the latest branch of the plugin first MOODLE_403_STABLE and then backport as required to later versions?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants