Schülerberichte und erweiterte Deckblatt-Bausteine ergänzen
CI / build-and-test (push) Canceled after 0s

This commit is contained in:
admin committed 2026-10-22 11:24:43 +02:00
1 parent 336869e75f
commit e2f019667a
31 files changed
+961 -14

No files matched your search

@@ -27,6 +27,7 @@ public partial class StudentDetailView : UserControl
vm.OnConductParentCall = ShowParentCallSessionDialog;
vm.OnManageStudent = ShowManageStudentDialog;
vm.OnCreateLetter = ShowCreateLetterDialog;
vm.OnCreateStudentReport = ShowStudentReportDialog;
}
private async Task<Contact?> ShowContactDialog(Contact? contact)
@@ -58,6 +59,22 @@ public partial class StudentDetailView : UserControl
await LetterDialogs.ShowCreateLetterDialogAsync(owner, student);
}
private async Task ShowStudentReportDialog()
{
if (TopLevel.GetTopLevel(this) is not Window owner ||
DataContext is not StudentDetailViewModel { Student: { } student }) return;
var vm = new StudentReportDialogViewModel(student,
App.Services.GetRequiredService<IGroupMembershipRepository>(),
App.Services.GetRequiredService<IGroupRepository>(),
App.Services.GetRequiredService<IInterimGradeRepository>(),
App.Services.GetRequiredService<StudentReportService>(),
App.Services.GetRequiredService<LehrerApp.Templating.ITemplateRenderer>(),
App.Services.GetRequiredService<LehrerApp.Core.Services.SchoolYearService>(),
[App.Services.GetRequiredService<LehrerApp.Templating.TemplateStore>(),
App.Services.GetRequiredService<LehrerApp.Templating.WorksheetTemplateStore>().Store]);
await new StudentReportDialog { DataContext = vm }.ShowDialog(owner);
}
private void ShowAddressViewer(ContactItem contact)
{
if (!contact.HasAddress) return;