From 89d33a261d657aadff67f37a76c489809b0bb6fd Mon Sep 17 00:00:00 2001 From: Daniel Schick Date: Thu, 24 Feb 2022 12:38:19 +0100 Subject: [PATCH] =?UTF-8?q?Korrekturen=20f=C3=BCr=207.0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ENI2/DetailRootControl.xaml.cs | 48 +++---------------- .../BorderPoliceDetailControl.xaml | 2 +- .../OverViewDetailControl.xaml.cs | 46 ------------------ .../WasteDetailControl.xaml | 13 ++++- .../WasteDetailControl.xaml.cs | 15 ++++-- ENI2/ENI2.csproj | 4 +- ENI2/EditControls/EditCREWDialog.xaml | 4 +- ENI2/EditControls/EditCREWDialog.xaml.cs | 8 ++-- ENI2/EditControls/EditPasDialog.xaml.cs | 4 +- ENI2/EditControls/EditWasteReceiptDialog.xaml | 8 ++-- .../SelectImportClassesDialog.xaml.cs | 6 +-- ENI2/EditControls/VisitIdDialog.xaml.cs | 6 +-- ENI2/Excel/ExcelReader.cs | 9 ++-- ENI2/Excel/ExcelUtil.cs | 21 +++++--- ENI2/Util/UIHelper.cs | 3 ++ SQL/Update_6.x_To_7.0.sql | 7 +++ bsmd.database/DBManager.cs | 2 +- bsmd.database/WAS.cs | 17 +++++++ bsmd.database/WAS_RCPT.cs | 44 +++++++++++++++-- bsmd.database/WasteReceived.cs | 9 ++++ bsmd.hisnord/Request.cs | 4 +- 21 files changed, 147 insertions(+), 133 deletions(-) diff --git a/ENI2/DetailRootControl.xaml.cs b/ENI2/DetailRootControl.xaml.cs index 76e5de7f..5f2bb529 100644 --- a/ENI2/DetailRootControl.xaml.cs +++ b/ENI2/DetailRootControl.xaml.cs @@ -741,13 +741,7 @@ namespace ENI2 MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V182, "No Schengen details", null, "CREWA", crewa.Identifier, "CREWA"); mv.MessageGroupName = Properties.Resources.textOverview; vViolations.Add(mv); - } - if(!crewaIsSchengen && crewa.HasSchengenDetails) - { - MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V182, "Schengen details but checkbox not set", null, "CREWA", crewa.Identifier, "CREWA"); - mv.MessageGroupName = Properties.Resources.textOverview; - vViolations.Add(mv); - } + } } } @@ -769,13 +763,7 @@ namespace ENI2 MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V182, "No Schengen details", null, "CREWD", crewd.Identifier, "CREWD"); mv.MessageGroupName = Properties.Resources.textOverview; vViolations.Add(mv); - } - if (!crewdIsSchengen && crewd.HasSchengenDetails) - { - MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V182, "Schengen details but checkbox not set", null, "CREWD", crewd.Identifier, "CREWD"); - mv.MessageGroupName = Properties.Resources.textOverview; - vViolations.Add(mv); - } + } } } @@ -798,25 +786,13 @@ namespace ENI2 MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V202, "No Schengen details", null, "PASA", pasa.Identifier, "PASA"); mv.MessageGroupName = Properties.Resources.textOverview; vViolations.Add(mv); - } - if (!pasIsSchengen && pasa.HasSchengenDetails) - { - MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V202, "Schengen details but checkbox not set", null, "PASA", pasa.Identifier, "PASA"); - mv.MessageGroupName = Properties.Resources.textOverview; - vViolations.Add(mv); - } + } if(pasIsPAX && !pasa.HasPAXDetails) { MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V203, "No PAX details", null, "PASA", pasa.Identifier, "PASA"); mv.MessageGroupName = Properties.Resources.textOverview; vViolations.Add(mv); - } - if(!pasIsPAX && pasa.HasPAXDetails) - { - MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V203, "PAX details but checkbox not set", null, "PASA", pasa.Identifier, "PASA"); - mv.MessageGroupName = Properties.Resources.textOverview; - vViolations.Add(mv); - } + } } } @@ -839,25 +815,13 @@ namespace ENI2 MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V202, "No Schengen details", null, "PASD", pasd.Identifier, "PASD"); mv.MessageGroupName = Properties.Resources.textOverview; vViolations.Add(mv); - } - if (!pasdIsSchengen && pasd.HasSchengenDetails) - { - MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V202, "Schengen details but checkbox not set", null, "PASD", pasd.Identifier, "PASD"); - mv.MessageGroupName = Properties.Resources.textOverview; - vViolations.Add(mv); - } + } if (pasdIsPAX && !pasd.HasPAXDetails) { MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V203, "No PAX details", null, "PASD", pasd.Identifier, "PASD"); mv.MessageGroupName = Properties.Resources.textOverview; vViolations.Add(mv); - } - if (!pasdIsPAX && pasd.HasPAXDetails) - { - MessageViolation mv = RuleEngine.CreateViolation(ValidationCode.V203, "PAX details but checkbox not set", null, "PASD", pasd.Identifier, "PASD"); - mv.MessageGroupName = Properties.Resources.textOverview; - vViolations.Add(mv); - } + } } } diff --git a/ENI2/DetailViewControls/BorderPoliceDetailControl.xaml b/ENI2/DetailViewControls/BorderPoliceDetailControl.xaml index d8f54db7..a5937371 100644 --- a/ENI2/DetailViewControls/BorderPoliceDetailControl.xaml +++ b/ENI2/DetailViewControls/BorderPoliceDetailControl.xaml @@ -83,7 +83,7 @@ - + diff --git a/ENI2/DetailViewControls/OverViewDetailControl.xaml.cs b/ENI2/DetailViewControls/OverViewDetailControl.xaml.cs index b0e5aa51..a69af06e 100644 --- a/ENI2/DetailViewControls/OverViewDetailControl.xaml.cs +++ b/ENI2/DetailViewControls/OverViewDetailControl.xaml.cs @@ -692,52 +692,6 @@ namespace ENI2.DetailViewControls } } - /* obsolete, da PDF jetzt lokal erzeugt werden können.. - * - private void buttonCreatePDF_Click(object sender, RoutedEventArgs e) - { - bool cannotCreateReport = false; - - for (int i = 0; i < this.Messages.Count; i++) - { - Message selectedMessage = this.Messages[i]; - - // 28.3. Diese Nachrichten sollten dabei nicht geprüft werden.. immer diese Spezialfälle - if ((selectedMessage.MessageNotificationClass == Message.NotificationClass.VISIT) || - (selectedMessage.MessageNotificationClass == Message.NotificationClass.TRANSIT) || - (selectedMessage.MessageNotificationClass == Message.NotificationClass.CREWD) || - (selectedMessage.MessageNotificationClass == Message.NotificationClass.PASD) || - (selectedMessage.MessageNotificationClass == Message.NotificationClass.STO)) continue; - - if ((selectedMessage.InternalStatus == Message.BSMDStatus.SENT) || (selectedMessage.InternalStatus == Message.BSMDStatus.TOSEND)) - { - cannotCreateReport = true; - break; - } - } - - if (cannotCreateReport) - { - MessageBox.Show("Cannot create report: some messages still in status TOSEND / SENT", Properties.Resources.textCaptionError, MessageBoxButton.OK, MessageBoxImage.Exclamation); - return; - } - - for (int i = 0; i < this.dataGridMessages.SelectedItems.Count; i++) - { - Message selectedMessage = this.dataGridMessages.SelectedItems[i] as Message; - selectedMessage.LastStatus = selectedMessage.InternalStatus; - selectedMessage.InternalStatus = Message.BSMDStatus.REPORT; - selectedMessage.ReportingPartyId = App.UserId; // wichtig damit der Richtige(!) die Mail mit dem PDF bekommt - DBManager.GetSingleCon(Properties.Settings.Default.ConnectionString).Save(selectedMessage); - } - - - this.Core.ReportStatus = MessageCore.ReportStatusEnum.SINGLE; - DBManager.GetSingleCon(Properties.Settings.Default.ConnectionString).Save(this.Core); - this.dataGridMessages.Items.Refresh(); - } - */ - private void buttonSystemErrors_Click(object sender, RoutedEventArgs e) { if (this.dataGridMessages.SelectedItems.Count > 0) diff --git a/ENI2/DetailViewControls/WasteDetailControl.xaml b/ENI2/DetailViewControls/WasteDetailControl.xaml index 08d06950..2db7b34d 100644 --- a/ENI2/DetailViewControls/WasteDetailControl.xaml +++ b/ENI2/DetailViewControls/WasteDetailControl.xaml @@ -146,6 +146,7 @@ + + + + + + +