From d5d0045adbe640f07684b8f2d325d9e33b802a5a Mon Sep 17 00:00:00 2001 From: Daniel Schick Date: Wed, 4 Jan 2023 15:36:48 +0100 Subject: [PATCH] Korrekturen nach Test Christin I --- ENI2/DetailRootControl.xaml.cs | 4 ++++ ENI2/EditControls/VisitIdDialog.xaml.cs | 12 ++++++------ ENI2/MainWindow.xaml.cs | 4 ++-- bsmd.database/Message.cs | 2 +- bsmd.database/MessageCore.cs | 2 -- 5 files changed, 13 insertions(+), 11 deletions(-) diff --git a/ENI2/DetailRootControl.xaml.cs b/ENI2/DetailRootControl.xaml.cs index adc79dc8..79bb26f0 100644 --- a/ENI2/DetailRootControl.xaml.cs +++ b/ENI2/DetailRootControl.xaml.cs @@ -893,11 +893,15 @@ namespace ENI2 #endregion #region 4.1.23 no CREW effects warning for DE + if (crewaMessage != null) { MessageViolation mv = crewaMessage.ViolationList.Find((x) => x.PropertyName.Equals("Effects") && (x.ViolationCode == (int)ValidationCode.TRUNCATE)); if ((mv != null) && !Core.IsDK) crewaMessage.ViolationList.Remove(mv); + } + if(crewdMessage != null) + { MessageViolation mvd = crewdMessage.ViolationList.Find((x) => x.PropertyName.Equals("Effects") && (x.ViolationCode == (int)ValidationCode.TRUNCATE)); if ((mvd != null) && !Core.IsDK) crewdMessage.ViolationList.Remove(mvd); diff --git a/ENI2/EditControls/VisitIdDialog.xaml.cs b/ENI2/EditControls/VisitIdDialog.xaml.cs index 218928f7..8c065771 100644 --- a/ENI2/EditControls/VisitIdDialog.xaml.cs +++ b/ENI2/EditControls/VisitIdDialog.xaml.cs @@ -25,12 +25,12 @@ namespace ENI2.EditControls } private void VisitIdDialog_Loaded(object sender, RoutedEventArgs e) - { + { this.OKClicked += VisitIdDialog_OKClicked; - List> comboDataSource = new List>() + List> comboDataSource = new List>() { - new KeyValuePair( Message.NSWProvider.DUDR, "HIS-Nord" ), - new KeyValuePair( Message.NSWProvider.DBH, "DBH" ), + new KeyValuePair( Message.NSWProvider.DUDR, "HIS-Nord" ), + new KeyValuePair( Message.NSWProvider.DBH, "DBH" ), new KeyValuePair(Message.NSWProvider.DBH_MAERSK, "DBH / Maersk") }; @@ -118,8 +118,8 @@ namespace ENI2.EditControls isComplete &= this.datePickerETA.SelectedDate.HasValue; // ETA - bool imo_OR_eni = ((doubleUpDownIMO.Value.HasValue) && (doubleUpDownIMO.Value >= 1000000) && (doubleUpDownIMO.Value <= 9999999)) || - ((doubleUpDownENI.Value.HasValue) && (doubleUpDownENI.Value >= 100000) && (doubleUpDownENI.Value <= 99999999)); + bool imo_OR_eni = (doubleUpDownIMO.Value.HasValue && (doubleUpDownIMO.Value >= 1000000) && (doubleUpDownIMO.Value <= 9999999)) || + (doubleUpDownENI.Value.HasValue && (doubleUpDownENI.Value >= 100000) && (doubleUpDownENI.Value <= 99999999)); isComplete &= imo_OR_eni; diff --git a/ENI2/MainWindow.xaml.cs b/ENI2/MainWindow.xaml.cs index 745298dc..5fa1c4a2 100644 --- a/ENI2/MainWindow.xaml.cs +++ b/ENI2/MainWindow.xaml.cs @@ -410,7 +410,7 @@ namespace ENI2 MessageCore newCore = new MessageCore(); VisitIdDialog visitIdDialog = new VisitIdDialog(); - visitIdDialog.Core = newCore; + visitIdDialog.Core = newCore; visitIdDialog.Closed += (senderDialog, closeArgs) => { VisitIdDialog closedDialog = senderDialog as VisitIdDialog; @@ -435,7 +435,7 @@ namespace ENI2 bsmd.database.Util.CreateMessagesForCore(closedDialog.Core, null, userEntity); // watchdog registrieren - this._dbWatchDog.Register(closedDialog.Core); + this._dbWatchDog.Register(closedDialog.Core); // Wartedialog anzeigen ShowIdDialog showIdDialog = new ShowIdDialog(closedDialog.Core); diff --git a/bsmd.database/Message.cs b/bsmd.database/Message.cs index a7f28999..27ec8ed4 100644 --- a/bsmd.database/Message.cs +++ b/bsmd.database/Message.cs @@ -173,7 +173,7 @@ namespace bsmd.database public enum NSWProvider { [Description("Unspecified")] - UNDEFINED, + UNDEFINED, DBH, diff --git a/bsmd.database/MessageCore.cs b/bsmd.database/MessageCore.cs index dc8e0950..758623e3 100644 --- a/bsmd.database/MessageCore.cs +++ b/bsmd.database/MessageCore.cs @@ -212,8 +212,6 @@ namespace bsmd.database { get { - if ((int)_initialHIS > 3) // pre 7.0 declarations may have "Test-" HIS set - return _initialHIS - 3; return _initialHIS; } set