Help & User Guide
Complete guide to using Vidhyantra — from first-time setup to daily operations.
Overview
Vidhyantra is a web-based school timetable management system. It has two sides:
- Public side — Anyone (teachers, students, parents) can view timetables at the school's URL. No login required.
- Admin side — School staff log in at
/adminto manage everything: classes, teachers, subjects, timetable slots, substitutions, and more.
Public Timetable Views
Visit the school website and search from the home page, or go directly to a URL:
| URL | What it shows |
|---|---|
/8a | Timetable for Section 8A |
/tony-stark | All periods taught by that teacher |
/math | All classes where Math is taught |
/coaching/8a | Section 8A timetable under the Coaching profile |
Substitution badges:If a teacher is absent today or tomorrow, a yellow "Sub" badge appears on that slot showing the substitute teacher's name. A toggle button at the top-right of the grid turns this off. Printing always shows the original timetable.
Holiday banner: If a holiday or exam day has been set for today, the timetable is replaced with a banner showing the reason.
Admin Login
- Go to the provided admin URL.
- Enter your email and password.
- You are redirected to the admin dashboard.
To log out, click the Logout button at the bottom of the sidebar.
Admin Panel Layout
The left sidebar has five groups of navigation links:
| Group | Pages |
|---|---|
| (top) | Dashboard |
| Setup | Import, Classes, Sections, Subjects, Teachers, Assignments |
| Schedule | Periods, Period Configs, Curriculum, Auto Generate, Timetable, Bulk Download |
| Operations | Substitutions, Overrides |
| Admin | Profiles, Audit Log |
On mobile, tap the blue hamburger button (top-left) to open the sidebar.
First-Time Setup
Complete these steps in order before building a timetable.
Step 1 — Classes
AdminSetupClassesCreate one row per class level (e.g. Class 6, Class 7, Class 8).
Click Add Class, fill in the name, click Save.
Step 2 — Sections
AdminSetupSectionsEach section belongs to a class and gets its own public URL slug.
| Field | Example | Notes |
|---|---|---|
| Class | Class 8 | Select from dropdown |
| Name | 8A | Display name |
| Slug | 8a or 8-a | Public URL — must be globally unique |
| Period Config | (optional) | Leave blank to use the profile's default periods |
Toggle "Use class-section format" on to auto-generate slugs like 8-a; off for plain a.
Step 3 — Subjects
AdminSetupSubjects| Field | Example | Notes |
|---|---|---|
| Name | Mathematics | |
| Slug | math | Public URL — must be globally unique |
| Color | #E53E3E | Shown as a color dot throughout the app |
Step 4 — Teachers
AdminSetupTeachers| Field | Example | Notes |
|---|---|---|
| Name | Tony Stark | |
| Slug | tony-stark | Auto-generated from name, editable |
| Max Periods/Week | 24 | Optional — leave blank for no limit |
ram-rai, ram-sharma).Step 5 — Assignments
AdminSetupAssignmentsAssignments link a teacher to a subject in a section. The system uses this to know who is qualified to teach what, and where.
Click Add Assignment, select Teacher, Section, and Subject, then click Save.
Configuring Periods
AdminSchedulePeriodsPeriods define the time slots in your school day (e.g. Period 1: 10:15 AM – 11:00 AM).
| Field | Notes |
|---|---|
| Label | e.g. "Period 1", "Lunch Break" |
| Start / End Time | 12-hour or 24-hour format |
| Is Break | Tick for Assembly, Lunch, Recess — break rows span all columns |
| Sort Order | Controls display order (lower number = appears earlier) |
Period Configs (Named Schedules)
AdminSchedulePeriod ConfigsA Period Config is a saved template of periods you can switch between — e.g. a regular-day schedule and an exam-day schedule with shorter periods.
- Left panel: list of configs. Click one to edit it.
- Right panel: slot editor — add, delete, reorder slots, toggle break.
Applying a config to the school:
- Select the config on the left.
- Click Apply to School (or "Apply to [Profile Name]").
- This copies all config slots to the live Periods table for that profile, replacing current periods.
You can also assign a config directly to a section (in the Sections page). That section's timetable builder will then use that config's periods instead of the profile default.
Curriculum Setup
AdminScheduleCurriculumCurriculum tells the auto-generator how many periods per week each subject should be taught for each class. Complete this before running Auto Generate.
- Left panel: list of all classes. Click a class to work on its curriculum.
- Right panel: a row for each subject that has at least one teacher assignment for that class. Subjects with no assigned teacher are hidden — assign a teacher first in Assignments.
| Field | Example | Notes |
|---|---|---|
| Periods/Week | 6 | Total slots per week for this subject in this class |
| Double Pairs | 2 | How many of those slots are double-period pairs |
The page shows a live breakdown below each row — e.g. 6 periods/week → 2×double + 2×single.
Double Pairs are automatically clamped — you cannot set more double pairs than half the periods/week value. With 5 periods/week, the maximum is 2 double pairs.
Each subject row has its own Save button. Changes are not saved until you click it.
Building the Timetable
There are two methods: Auto Generate (faster) or the Manual Timetable Builder (full control). You can combine both — auto-generate first, then fix individual slots manually.
Auto Generate (recommended)
AdminScheduleAuto GenerateStep 1 — Configure
- Reshuffle all? — Off by default. With it off, manually placed slots are locked and the algorithm works around them. Turn it on to clear everything and start fresh (a confirm dialog appears).
- A curriculum summary lists each class with total periods/week targets.
- Click Generate Preview.
Step 2 — Preview
The algorithm runs entirely in memory — nothing is saved yet. It shows:
- A section-by-section grid preview — click section buttons at the top to switch.
- Stats cards: total slots placed, unique subjects covered, warnings count.
- Free Slots Filled (purple card): extra slots placed for subjects with teacher assignments but no curriculum entry.
- Warnings list: subject/section combos that could not be fully scheduled — place these manually in the Timetable Builder.
If the preview looks good, click Confirm & Save. Otherwise click Back to adjust.
Step 3 — Done
Slots are written to the database. Go to Timetable to view or manually adjust remaining gaps.
Manual Timetable Builder
AdminScheduleTimetableSelect a section from the dropdown. The grid shows all days (Sun–Fri) × all periods.
Adding a slot:
- Click any empty cell.
- A modal opens — select Subject and Teacher.
- The teacher dropdown only shows teachers assigned to that subject in that section.
- Click Save. Conflict detection blocks saving if the teacher is already booked at that time.
- Edit / delete: Click an existing slot to edit or delete it.
- Double periods: Check "Double period" in the modal. The next consecutive period is reserved automatically and both slots link together.
- Workload panel: Shown below the grid when any teacher has a max periods/week limit set — lists name, assigned count, max, and status.
Substitute Teachers
AdminOperationsSubstitutionsThis page has four tabs:
Tab 1 — Mark Absent (primary workflow)
Use this tab every morning when a teacher is absent.
- Select the absent teacher from the list. If the teacher has an active leave record, their name appears in the orange "On Leave Today" banner.
- Choose leave type: Full Day, AM (morning), or PM (afternoon).
- Optionally select a reason category: On Leave / Sick / Meeting / Personal / Other, plus a free-text note.
- All periods the absent teacher has today are listed below.
- For each period, select a substitute teacher from the dropdown. Only free teachers are shown (not already booked at that time in any profile).
- Click Save All to assign all substitutes in one click.
The date selector defaults to today. Use the ← → arrows or Today / Next Week buttons to plan ahead. On Friday or Saturday the default automatically jumps to next week.
Tab 2 — By Section
A full-week grid view. Each column is a day; each row is a period. Click any cell to open the substitution modal for that slot.
- Holiday columns (amber): substitution assignment is blocked on override days.
- Unsubstituted slots (red ring): today's periods that still need a substitute.
Tab 3 — All Records
A searchable table of all substitution records grouped by date. You can edit reasons inline or revert a substitution. Records are never deleted — reverting sets a cancelled timestamp.
Tab 4 — Leaves
Track multi-day teacher absences (training, sick leave).
- Click Add Leave.
- Select teacher, start/end dates, leave type, and reason.
- The leave appears in the "On Leave Today" banner for any day it covers.
Holidays & Exam Days (Overrides)
AdminOperationsOverridesCreate override records for days when the normal timetable does not apply.
| Field | Notes |
|---|---|
| Date | The affected date |
| Type | holiday, exam, or custom |
| Label | e.g. "Dashain Holiday", "Half-Yearly Exam" |
| Affected Sections | Leave empty for school-wide; pick sections for section-specific |
Where overrides appear:
- Public timetable: a colored banner replaces the timetable grid on that day.
- Substitutions By Section tab: holiday columns are amber and assignment is blocked.
- Admin Dashboard: an amber banner lists all overrides in the next 30 days.
Multiple Timetable Profiles
AdminAdminProfilesA profile is a separate independent timetable (e.g. Main Academic, Coaching, Exam). Each profile has its own periods, timetable slots, and substitutions. Teachers and sections are shared.
Creating a new profile:
- Go to Profiles, click Add Profile.
- Fill in Name, Slug (public URL prefix), Type, and Color.
- The slug must be unique across all sections, teachers, and subjects.
- Switch to the new profile using the sidebar switcher.
- Set up Periods, Curriculum, and Timetable for that profile independently.
Switching profiles: Click the profile name at the top of the sidebar. All Schedule pages immediately filter to that profile.
Public URL for a non-default profile: /coaching/8a (profile slug + section slug).
Audit Log
AdminAdminAudit LogEvery create, update, and delete by any admin is logged here with date/time, which admin, what table/record, and before/after values (expandable JSON diff).
Use the filter bar to narrow by profile, table, action type, date range, or admin email.
Print & Download
On any public timetable page (section / teacher / subject view), a toolbar appears at the top:
- Print — opens the browser print dialog. Formatted for A4/Letter. Substitution badges are hidden; the original timetable is always printed.
- PDF (Color) — generates a color-coded PDF with subject colors.
- PDF (B&W) — black-and-white version, ideal for photocopying.
- PNG Image — high-resolution image of the timetable grid.
Bulk Download
AdminScheduleBulk DownloadDownload timetables for all sections at once as a single ZIP file.
- Go to Admin → Schedule → Bulk Download.
- Sections are listed grouped by class, all pre-selected. Uncheck any you want to skip.
- Choose a format: PDF Color, PDF B&W, or PNG.
- Click Download ZIP. A progress bar tracks each section as it is generated.
- The ZIP file downloads automatically with one file per section.
8a-color-2026-06-26.pdf. The ZIP itself is named after the active profile.Roles & Permissions
| Role | Can do |
|---|---|
| admin | Full access — create, edit, delete everything |
| viewer | Read-only dashboard — no edit or delete buttons |
Role is set in the user_roles table by the super-admin. To change a role, go to the Supabase dashboard → Table Editor → user_roles, find the user's UUID, and update the role column to admin.
Quick Reference — URL Patterns
| URL | What it shows |
|---|---|
/ | Home page with search |
/8a | Section 8A timetable (default profile) |
/tony-stark | Teacher timetable |
/math | Subject timetable (all sections) |
/coaching/8a | Section 8A under Coaching profile |
/help | This page |
/admin | Admin dashboard |
/admin/classes | Classes |
/admin/sections | Sections |
/admin/subjects | Subjects |
/admin/teachers | Teachers |
/admin/assignments | Teacher assignments |
/admin/periods | Live periods for current profile |
/admin/period-configs | Period schedule templates |
/admin/curriculum | Periods/week targets per subject |
/admin/autogenerate | Auto generation wizard |
/admin/timetable | Manual timetable builder |
/admin/download | Bulk download (ZIP) |
/admin/substitutions | Substitute teacher management |
/admin/overrides | Holidays & exam day overrides |
/admin/profiles | Timetable profiles |
/admin/audit | Audit log |