ORVIAN supports two onboarding paths: the platform Owner creating a school directly from the admin panel, and a school registering itself via the public sign-up page. Both flows lead into a wizard that configures the school’s academic structure, geographic data, and subscription plan. The Owner flow additionally creates the initial Director account. When the wizard completes, listener classes and post-commit callbacks fire to build the full tenant environment.Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Elian-D/ORVIAN/llms.txt
Use this file to discover all available pages before exploring further.
Owner-Initiated Setup
The Owner accesses/admin/setup, which renders the SchoolWizard Livewire component — a 5-step guided form backed by BaseSchoolWizard inheritance.
| Step | Content |
|---|---|
| 1 — School Data | Institution name, SIGERD code, phone, management regime, and modality |
| 2 — Geographic Info | Province, municipality, regional education authority, and educational district (cascaded selectors) |
| 3 — Academic Structure | Education levels, shifts, section labels, academic year dates, and optional technical titles for upper-secondary |
| 4 — Plan Selection | Choose a subscription plan from the active plan catalog |
| 5 — Director Account | Name, email, and password for the initial School Principal user |
CompleteOnboardingAction is called. It creates the school record, provisions the Director user account, and fires the SchoolConfigured event inside a database transaction.
Self-Registration Flow
A school administrator visits/sign-up. The RegisterUser Livewire component creates a stub school — a minimal school record with no academic structure yet. The administrator is then directed to the TenantSetupWizard, a 4-step variant of the same wizard that covers the same Steps 1–4 (School Data, Geographic Info, Academic Structure, and Plan Selection). The currently authenticated user is assigned the School Principal role automatically — no separate Director form is shown.
On completion, CompleteTenantOnboardingAction updates the stub school with the wizard data and fires SchoolConfigured using the same event pipeline.
What Happens on Completion
WhenSchoolConfigured fires, two listener classes handle post-onboarding setup. They are registered via manual Event::listen calls (not auto-discovered):
SetupAcademicStructure— reads the wizard configuration and creates allSchoolSectionrecords for every configured level, shift, and section label.CreateInitialAcademicYear— creates the firstAcademicYearrecord using the start and end dates provided during the wizard.
ChatwootService::syncUserAsAgent() is called directly inside the action (not via a listener). This call is placed in DB::afterCommit to ensure it only runs after the outer transaction commits successfully, avoiding nested-transaction callback issues.
School Settings
After onboarding, Directors manage their school’s institutional profile at/app/settings/school — rendered by the SchoolSettings Livewire component (App\Livewire\App\Settings\SchoolSettings). This page requires the settings.view or settings.update permission.
The settings form covers:
- School logo — upload or replace the institutional logo (JPG, PNG, WEBP, max 2 MB). The previous file is deleted from
storage/app/public/schools/{id}/branding/before the new one is stored. - Institutional data — name, SIGERD code, phone number, address detail, management regime (
regimen_gestion), and modality. - Geographic cascade selectors — powered by the
GeographicSelectscomponent. Selecting a province resets the municipality; selecting a regional education authority resets the educational district. - Active academic year — displayed as a read-only field. The value is the name of the
AcademicYearwhereis_active = truefor the current school.
/admin/schools/{school} (SchoolShow component).
School Status
Every school has two independent boolean status flags:| Flag | Meaning |
|---|---|
is_active | Whether the school is fully operational in the platform. Set to true after successful onboarding. |
is_suspended | Whether the school has been suspended due to payment issues. A school can be active but suspended. |
EnsureSchoolIsActive middleware intercepts every request to /app/* routes and enforces these rules:
- If
is_suspended = true→ redirect to thesuspended.noticeview. - If
is_active = false→ redirect to theinactive.noticeview.
/admin/schools/{school} (SchoolShow) or from the list at /admin/schools (SchoolIndex). ORVIAN enforces a business rule: a school must be suspended before it can be deactivated. Attempting to deactivate an active, non-suspended school returns a validation error notification.