metatroncubeswdev a36c89222b O5: mc_education_timetable - one dataset, three views, conflict-checked
Serves Demo Scene 7: mc.timetable.slot (batch, weekday, period,
subject, teacher, room, year, term) is the single dataset. "Three
read views" are three entry points into that same model rather than
three separate data structures - a stat button on mc.batch, on
mc.teacher, and on mc.student (resolved through the student's active
enrollment to their batch) each open the same list/search action with
a different domain. Auto-generation is out of scope per spec; this
module only configures slots by hand (demo data is a real Mon-Fri
week for Grade 8-A, since a timetable is a recurring weekly pattern
and one week fully represents it, unlike attendance/fees which
genuinely need a run of history).

Conflict prevention ("a teacher or a room cannot hold two slots in
the same weekday+period") follows the same two-layer pattern used for
mc.academic.year.is_current and mc.enrollment in O1: a partial unique
index per conflict type (teacher, room, and - not explicitly asked
for but an obvious extension of the same rule - batch, since a batch
can't be in two places at once either) is the actual guarantee, and a
pre-check in create()/write() raises a readable ValidationError
before the insert/update, not after, for the same reason established
building mc.enrollment: the DB index fires first and the friendly
message is unreachable otherwise.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-09-11 12:53:47 -04:00

23 lines
695 B
Python

{
"name": "School ERP - Timetable",
"version": "19.0.1.0.0",
"category": "Education",
"summary": "One timetable dataset, viewed by batch, by teacher, or by student.",
"author": "Metatroncube Software Solutions LLP",
"license": "Other proprietary",
"depends": ["mc_education_base"],
"data": [
"security/ir.model.access.csv",
"views/mc_timetable_slot_views.xml",
"views/mc_batch_views.xml",
"views/mc_teacher_views.xml",
"views/mc_student_views.xml",
"views/mc_education_timetable_menus.xml",
],
"demo": [
"demo/mc_timetable_slot_demo.xml",
],
"installable": True,
"application": False,
}