[docs] Security/capability checks in [reportbuilder]
Open
Nobody has claimed this yet.
documentation
enhancement
help wanted
needs-triage
- Dominant language
- TypeScript
- Stars
- 74
- Forks
- 652
- Avg merge
- 2d 50m
- Merged PRs (30d)
- 12
Description
What is the Moodle feature that needs documenting?
versioned_docs/version-5.0/apis/core/reportbuilder
Could you add documentation for security/capability checks please :)
I think to restrict access to a data entity it is the is_available function?
eg: in local/myplugin/classes/reportbuilder/local/entities/mydata.php
public function is_available(): bool {
return has_capability('local/myplugin:viewreport', context_system::instance());
}
Is this documentation specific to a Moodle version?
None
Are you able to provide a patch for this?
None
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with versioned_docs/version-5.0/apis/core/reportbuilder and review the surrounding reportbuilder API guidance. Use the issue's is_available() example and capability check as the reference point; done means the documentation explains how to restrict a data entity's access and includes an applicable example.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- authorization, documentation
- Issue type
- Documentation
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100