Edit Stammdaten Mitarbeitsessions
This commit is contained in:
@@ -23,6 +23,7 @@ public partial class ParticipationTabView : UserControl
|
||||
{
|
||||
_vm = vm;
|
||||
vm.OnAddSession = ShowAddSessionDialog;
|
||||
vm.OnEditSession = ShowEditSessionDialog;
|
||||
vm.OnQuickInput = ShowQuickInputDialog;
|
||||
vm.OnStatusQuickInput = ShowStatusQuickInputDialog;
|
||||
vm.OnComputeGrade = ShowComputeGradeDialog;
|
||||
@@ -283,6 +284,17 @@ public partial class ParticipationTabView : UserControl
|
||||
return ok ? vm.Result : null;
|
||||
}
|
||||
|
||||
private async Task<LehrerApp.Core.Models.ParticipationSession?> ShowEditSessionDialog(
|
||||
LehrerApp.Core.Models.ParticipationSession session)
|
||||
{
|
||||
var vm = new AddSessionDialogViewModel(session);
|
||||
var dialog = new AddSessionDialog { DataContext = vm };
|
||||
var owner = TopLevel.GetTopLevel(this) as Window;
|
||||
if (owner is null) return null;
|
||||
var ok = await dialog.ShowDialog<bool>(owner);
|
||||
return ok ? vm.Result : null;
|
||||
}
|
||||
|
||||
private async Task ShowQuickInputDialog(ParticipationTabViewModel tabVm)
|
||||
{
|
||||
if (tabVm.StudentRows.Count == 0) return;
|
||||
|
||||
Reference in New Issue
Block a user