Stundenplan Phase 3b: 3 more Stammdaten managers, first constraint editor, full test coverage
CI / go-lint (push) Has been skipped
CI / python-lint (push) Has been skipped
CI / nodejs-lint (push) Has been skipped
CI / test-go-school (push) Successful in 30s
CI / test-go-edu-search (push) Successful in 30s
CI / test-python-klausur (push) Failing after 3m6s
CI / test-python-agent-core (push) Successful in 20s
CI / test-nodejs-website (push) Successful in 21s

Frontend additions in studio-v2:
  - LehrerManager / FaecherManager / RaeumeManager — same CRUD pattern as
    Klassen, with entity-specific form fields and table columns.
  - regeln/TeacherUnavailableDayEditor — first constraint editor, joins
    against teachersApi to render a readable name in the dropdown and
    list. Falls back to a guidance banner when no teachers exist yet.
  - page.tsx wires up the new tabs; data-testid attributes added across
    managers so the Playwright suite can target them deterministically.

Tests:
  - school-service: timetable_constraints_more_test.go fills the
    remaining 9 constraint DTOs (TeacherMaxHoursDay/Week,
    TeacherExcludedSubject/Room, SubjectMinDayGap,
    SubjectContiguousWhenRepeated, SubjectDoubleLesson, ClassNoGaps,
    RoomRequiresType). 66 subtests total, all green.
  - studio-v2: e2e/stundenplan.spec.ts covers the page shell, tab
    navigation, Klassen CRUD with mocked backend, constraint editor's
    empty-teacher fallback, sidebar entry. All school-service calls
    intercepted via page.route() so the suite is hermetic.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
Benjamin Admin
2026-05-21 22:44:39 +02:00
parent f21ecf293b
commit 73636f76a2
8 changed files with 1048 additions and 3 deletions
+11 -2
View File
@@ -6,6 +6,10 @@ import { Sidebar } from '@/components/Sidebar'
import { ThemeToggle } from '@/components/ThemeToggle'
import { LanguageDropdown } from '@/components/LanguageDropdown'
import { KlassenManager } from './_components/KlassenManager'
import { LehrerManager } from './_components/LehrerManager'
import { FaecherManager } from './_components/FaecherManager'
import { RaeumeManager } from './_components/RaeumeManager'
import { TeacherUnavailableDayEditor } from './_components/regeln/TeacherUnavailableDayEditor'
import { setStundenplanToken, getStundenplanToken } from '@/lib/stundenplan/api'
type Tab = 'klassen' | 'lehrer' | 'faecher' | 'raeume' | 'periods' | 'curriculum' | 'assignments' | 'regeln'
@@ -102,15 +106,20 @@ export default function StundenplanPage() {
<section>
{tab === 'klassen' && <KlassenManager />}
{tab !== 'klassen' && (
{tab === 'lehrer' && <LehrerManager />}
{tab === 'faecher' && <FaecherManager />}
{tab === 'raeume' && <RaeumeManager />}
{tab === 'regeln' && <TeacherUnavailableDayEditor />}
{(tab === 'periods' || tab === 'curriculum' || tab === 'assignments') && (
<div
className={`rounded-2xl border backdrop-blur-xl p-8 text-center ${
isDark ? 'bg-white/5 border-white/10 text-white/60' : 'bg-white/80 border-black/10 text-slate-500'
}`}
data-testid="not-implemented"
>
<p className="text-lg">Noch nicht implementiert: {TABS.find(t => t.id === tab)?.label}</p>
<p className="text-sm mt-2">
Das Klassen-Modul ist der Prototyp. Die anderen Stammdaten und alle 15 Constraints folgen dem gleichen Muster.
Folgt dem gleichen Muster wie Klassen / Lehrer / Faecher / Raeume.
</p>
</div>
)}