first build possible
This commit is contained in:
@@ -55,18 +55,18 @@ public partial class AddGroupDialogViewModel : ObservableObject
|
||||
}
|
||||
|
||||
[RelayCommand]
|
||||
private bool Save()
|
||||
private void Save()
|
||||
{
|
||||
// Validierung
|
||||
if (string.IsNullOrWhiteSpace(Name))
|
||||
{
|
||||
ValidationMessage = "Bitte einen Namen eingeben.";
|
||||
return false;
|
||||
return;
|
||||
}
|
||||
if (GradeLevel is < 1 or > 13)
|
||||
{
|
||||
ValidationMessage = "Klassenstufe muss zwischen 1 und 13 liegen.";
|
||||
return false;
|
||||
return;
|
||||
}
|
||||
|
||||
Result = new LearningGroup
|
||||
@@ -82,7 +82,6 @@ public partial class AddGroupDialogViewModel : ObservableObject
|
||||
|
||||
_groups.Save(Result);
|
||||
ValidationMessage = "";
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user