From d2bab6e2c2f6ebcd333989a18c1c18467652d7a6 Mon Sep 17 00:00:00 2001 From: Daniel Schick Date: Tue, 17 Sep 2024 08:04:26 +0200 Subject: [PATCH] only allow saving if ETA time is greater than ETD time when shifting --- src/BreCalClient/EditShipcallControl.xaml.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/BreCalClient/EditShipcallControl.xaml.cs b/src/BreCalClient/EditShipcallControl.xaml.cs index 65ae975..745151b 100644 --- a/src/BreCalClient/EditShipcallControl.xaml.cs +++ b/src/BreCalClient/EditShipcallControl.xaml.cs @@ -222,6 +222,8 @@ namespace BreCalClient isEnabled &= (this.datePickerETD.Value.Value > DateTime.Now); if (this.datePickerETA.Value.HasValue) isEnabled &= (this.datePickerETA.Value.Value > DateTime.Now); + if (this.datePickerETA.Value.HasValue && this.datePickerETD.Value.HasValue) + isEnabled &= (this.datePickerETA.Value.Value > this.datePickerETD.Value.Value); break; } }