Erkennt Vertretungen, Ausfälle und Zusatzaufsichten aus dem persönlichen WebUntis-iCal-Feed und schreibt sie automatisch als SubstitutionEntry. Bekannter offener Bug: es tauchen weiterhin falsche Vertretungen für Stunden auf, die real unverändert sind — wird in einem Folge-Commit untersucht, deshalb vorerst auf diesem Branch statt main. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
28 lines
795 B
C#
28 lines
795 B
C#
using Avalonia.Controls;
|
|
using Avalonia.Interactivity;
|
|
using LehrerApp.Desktop.ViewModels.Planning;
|
|
|
|
namespace LehrerApp.Desktop.Views.Planning;
|
|
|
|
public partial class UntisMappingReviewDialog : Window
|
|
{
|
|
public UntisMappingReviewDialog() => InitializeComponent();
|
|
|
|
protected override void OnDataContextChanged(EventArgs e)
|
|
{
|
|
base.OnDataContextChanged(e);
|
|
if (DataContext is UntisMappingReviewDialogViewModel vm) _ = vm.LoadAsync();
|
|
}
|
|
|
|
private void OnSave(object? s, RoutedEventArgs e)
|
|
{
|
|
if (DataContext is UntisMappingReviewDialogViewModel vm && vm.SaveCommand.CanExecute(null))
|
|
{
|
|
vm.SaveCommand.Execute(null);
|
|
Close(true);
|
|
}
|
|
}
|
|
|
|
private void OnCancel(object? s, RoutedEventArgs e) => Close(false);
|
|
}
|