EM Elton Malumbot
← All projects
16Alpha 0.3.0 · Phase 2B · not deployed

Moodle Engineering · Role-Based Access Control

PENABUR School User Manager — Moodle Plugin

School mapping, manager authorization, and existing-user memberships

An alpha-stage Moodle local plugin (local_schoolusers v0.3.0) for administering school/category mappings, assigning school managers, and classifying existing students and teachers per school. Each Moodle installation remains independent; this plugin does not create accounts or synchronize servers.

My rolePHP and Moodle local plugin design · School/course-category mapping and access controls · Admin-only existing-user membership workflows
Core stackPHP · Moodle Local Plugin · Moodle XMLDB · Moodle Privacy API
DomainMoodle Engineering · Role-Based Access Control

01 · PROBLEM

The operational challenge

Schools sharing one Moodle installation need reliable boundaries for category mapping, manager access, and member counts without accidentally granting global account privileges or exposing other schools' identities.

02 · SOLUTION

How I approached it

I developed a Moodle-native PHP plugin with admin-only school and membership configuration, disjoint course-category mapping validation, explicit manager assignments and revocation, read-only scoped school dashboards, XMLDB schema upgrades, and Moodle Privacy API integrations. Access requires both an active manager assignment and the category-context view capability; administrator writes use session-key checks and independent authorization. Validation covered six official Moodle/PHP combinations in disposable environments, not production hosts.

PHP and Moodle local plugin design
School/course-category mapping and access controls
Admin-only existing-user membership workflows
Read-only manager dashboard and privacy support
XMLDB schema upgrades, regression tests and compatibility documentation

03 · KEY FEATURES

What the system does

01

Register, edit, activate, or deactivate school records mapped to existing Moodle course-category subtrees

02

Reject overlapping category trees and recheck current category ancestry during authorization

03

Assign, revoke, or reactivate eligible existing user accounts as school managers

04

Require both explicit active school assignment and local/schoolusers:view in the mapped category context

05

Manage active/inactive existing student and teacher memberships as site admin; one membership type per school

06

Read-only manager view of authorized schools and separate student, teacher and total counts—without individual names

07

Three Moodle XMLDB tables and upgrade logic, bilingual English/Indonesian interface, Privacy API discovery/export/approved erasure

08

Documented disposable-runtime test matrix: six Moodle/PHP combinations, 564 passing test executions and 1,530 assertions

09

Alpha Phase 2B only: no account creation, Excel/CSV import, cohort management, audit log, shared cross-server database or production deployment

04 · TECHNOLOGY

Tools and platform

PHPMoodle Local PluginMoodle XMLDBMoodle Privacy APIPostgreSQL Test MatrixRBACPHPUnitGitHub Actions

05 · OUTCOME

A versioned alpha plugin for safely categorizing existing Moodle users by school, with scoped manager summaries and test-backed upgrade/access controls. It is not a central user-provisioning service or a deployed production solution; institutional pilot, browser-level verification and exact environment checks remain pending.