User Guide

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 /admin to 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:

URLWhat it shows
/8aTimetable for Section 8A
/tony-starkAll periods taught by that teacher
/mathAll classes where Math is taught
/coaching/8aSection 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

  1. Go to the provided admin URL.
  2. Enter your email and password.
  3. You are redirected to the admin dashboard.

To log out, click the Logout button at the bottom of the sidebar.

If you see a read-only dashboard with no edit/delete buttons, your account has Viewer role. Ask the super-admin to upgrade your role.

Admin Panel Layout

The left sidebar has five groups of navigation links:

GroupPages
(top)Dashboard
SetupImport, Classes, Sections, Subjects, Teachers, Assignments
SchedulePeriods, Period Configs, Curriculum, Auto Generate, Timetable, Bulk Download
OperationsSubstitutions, Overrides
AdminProfiles, Audit Log

On mobile, tap the blue hamburger button (top-left) to open the sidebar.

If multiple Profiles are active, a profile switcher appears at the top of the sidebar. All Schedule pages always operate on the currently selected profile.

First-Time Setup

Complete these steps in order before building a timetable.

Step 1 — Classes

AdminSetupClasses

Create 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

AdminSetupSections

Each section belongs to a class and gets its own public URL slug.

FieldExampleNotes
ClassClass 8Select from dropdown
Name8ADisplay name
Slug8a or 8-aPublic 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
FieldExampleNotes
NameMathematics
SlugmathPublic URL — must be globally unique
Color#E53E3EShown as a color dot throughout the app

Step 4 — Teachers

AdminSetupTeachers
FieldExampleNotes
NameTony Stark
Slugtony-starkAuto-generated from name, editable
Max Periods/Week24Optional — leave blank for no limit
If two teachers share the same name, the system automatically appends their surname to make the slug unique (e.g. ram-rai, ram-sharma).

Step 5 — Assignments

AdminSetupAssignments

Assignments 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.

Assignments are school-wide — shared across all profiles. A teacher assigned to Math in Class 8A can be scheduled in any profile.

Configuring Periods

AdminSchedulePeriods

Periods define the time slots in your school day (e.g. Period 1: 10:15 AM – 11:00 AM).

FieldNotes
Labele.g. "Period 1", "Lunch Break"
Start / End Time12-hour or 24-hour format
Is BreakTick for Assembly, Lunch, Recess — break rows span all columns
Sort OrderControls display order (lower number = appears earlier)
Periods are profile-scoped — each profile has its own set of live periods. Use Period Configs to manage reusable templates.

Period Configs (Named Schedules)

AdminSchedulePeriod Configs

A 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:

  1. Select the config on the left.
  2. Click Apply to School (or "Apply to [Profile Name]").
  3. This copies all config slots to the live Periods table for that profile, replacing current periods.
Applying a config is blocked if timetable slots already exist for that profile, because existing slots reference old period IDs. Apply the config before building the timetable, or clear the timetable first.

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

AdminScheduleCurriculum

Curriculum 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.
FieldExampleNotes
Periods/Week6Total slots per week for this subject in this class
Double Pairs2How 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.

If the total periods/week across all subjects exceeds the grid capacity (teaching periods per day × 6 days), a red capacity warning appears. Reduce some subjects' periods/week before auto-generating.
Curriculum is class-level, not section-level. Class 8A and 8B share the same curriculum row for Class 8. The auto-generator schedules each section independently using the same targets.

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 Generate
Curriculum must be set up before this step.

Step 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

AdminScheduleTimetable

Select a section from the dropdown. The grid shows all days (Sun–Fri) × all periods.

Adding a slot:

  1. Click any empty cell.
  2. A modal opens — select Subject and Teacher.
  3. The teacher dropdown only shows teachers assigned to that subject in that section.
  4. 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

AdminOperationsSubstitutions

This page has four tabs:

Tab 1 — Mark Absent (primary workflow)

Use this tab every morning when a teacher is absent.

  1. 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.
  2. Choose leave type: Full Day, AM (morning), or PM (afternoon).
  3. Optionally select a reason category: On Leave / Sick / Meeting / Personal / Other, plus a free-text note.
  4. All periods the absent teacher has today are listed below.
  5. For each period, select a substitute teacher from the dropdown. Only free teachers are shown (not already booked at that time in any profile).
  6. 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.

The teacher dropdown shows a small badge with how many periods that teacher is already covering today — distribute the load fairly.

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).

  1. Click Add Leave.
  2. Select teacher, start/end dates, leave type, and reason.
  3. The leave appears in the "On Leave Today" banner for any day it covers.
Leaves do not auto-create substitution records. You still assign substitute teachers day-by-day from the Mark Absent tab.

Holidays & Exam Days (Overrides)

AdminOperationsOverrides

Create override records for days when the normal timetable does not apply.

FieldNotes
DateThe affected date
Typeholiday, exam, or custom
Labele.g. "Dashain Holiday", "Half-Yearly Exam"
Affected SectionsLeave 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

AdminAdminProfiles

A 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.

If you only have one profile the switcher is hidden and nothing changes — it works exactly like a single-schedule app.

Creating a new profile:

  1. Go to Profiles, click Add Profile.
  2. Fill in Name, Slug (public URL prefix), Type, and Color.
  3. The slug must be unique across all sections, teachers, and subjects.
  4. Switch to the new profile using the sidebar switcher.
  5. 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).

A teacher cannot be scheduled at the same wall-clock time in two different profiles. If two profiles overlap in time the system will block the second assignment.

Audit Log

AdminAdminAudit Log

Every 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.

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 Download

Download timetables for all sections at once as a single ZIP file.

  1. Go to Admin → Schedule → Bulk Download.
  2. Sections are listed grouped by class, all pre-selected. Uncheck any you want to skip.
  3. Choose a format: PDF Color, PDF B&W, or PNG.
  4. Click Download ZIP. A progress bar tracks each section as it is generated.
  5. The ZIP file downloads automatically with one file per section.
Files are named after the section slug and today's date — e.g. 8a-color-2026-06-26.pdf. The ZIP itself is named after the active profile.

Roles & Permissions

RoleCan do
adminFull access — create, edit, delete everything
viewerRead-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

URLWhat it shows
/Home page with search
/8aSection 8A timetable (default profile)
/tony-starkTeacher timetable
/mathSubject timetable (all sections)
/coaching/8aSection 8A under Coaching profile
/helpThis page
/adminAdmin dashboard
/admin/classesClasses
/admin/sectionsSections
/admin/subjectsSubjects
/admin/teachersTeachers
/admin/assignmentsTeacher assignments
/admin/periodsLive periods for current profile
/admin/period-configsPeriod schedule templates
/admin/curriculumPeriods/week targets per subject
/admin/autogenerateAuto generation wizard
/admin/timetableManual timetable builder
/admin/downloadBulk download (ZIP)
/admin/substitutionsSubstitute teacher management
/admin/overridesHolidays & exam day overrides
/admin/profilesTimetable profiles
/admin/auditAudit log
Last updated: 2026-06-26