Merge branch 'release/eni_7.7'

This commit is contained in:
Daniel Schick 2023-01-25 18:10:46 +01:00
commit 888f33ae09
34 changed files with 4117 additions and 622 deletions

View File

@ -109,6 +109,7 @@ namespace ENI2.Controls
thePicker.Value = new DateTime(year, month, day, hour, minute, 0); thePicker.Value = new DateTime(year, month, day, hour, minute, 0);
} }
catch (FormatException) { } catch (FormatException) { }
catch (ArgumentOutOfRangeException) { thePicker.Value = null; }
} }
} }
@ -125,6 +126,7 @@ namespace ENI2.Controls
thePicker.SelectedDate = new DateTime(year, month, day, 0, 0, 0); thePicker.SelectedDate = new DateTime(year, month, day, 0, 0, 0);
} }
catch (FormatException) { } catch (FormatException) { }
catch (ArgumentOutOfRangeException) { thePicker.SelectedDate = null; }
} }
} }

View File

@ -20,6 +20,7 @@
<DataGridTextColumn Header="{x:Static p:Resources.textLogin}" Binding="{Binding Logon}" IsReadOnly="True" Width="0.1*" /> <DataGridTextColumn Header="{x:Static p:Resources.textLogin}" Binding="{Binding Logon}" IsReadOnly="True" Width="0.1*" />
<DataGridTextColumn Header="{x:Static p:Resources.textEMail}" Binding="{Binding UserEMail}" IsReadOnly="True" Width="0.2*" /> <DataGridTextColumn Header="{x:Static p:Resources.textEMail}" Binding="{Binding UserEMail}" IsReadOnly="True" Width="0.2*" />
<DataGridCheckBoxColumn Header="{x:Static p:Resources.textAdministrator}" Binding="{Binding IsAdmin}" IsReadOnly="True" Width="0.1*" /> <DataGridCheckBoxColumn Header="{x:Static p:Resources.textAdministrator}" Binding="{Binding IsAdmin}" IsReadOnly="True" Width="0.1*" />
<DataGridCheckBoxColumn Header="{x:Static p:Resources.textEditor}" Binding="{Binding IsEditor}" IsReadOnly="True" Width="0.1*" />
<DataGridTextColumn Header="{x:Static p:Resources.textCreated}" Binding="{Binding Created}" IsReadOnly="True" Width="0.1*" /> <DataGridTextColumn Header="{x:Static p:Resources.textCreated}" Binding="{Binding Created}" IsReadOnly="True" Width="0.1*" />
<DataGridTextColumn Header="{x:Static p:Resources.textChanged}" Binding="{Binding Changed}" IsReadOnly="True" Width="0.1*" /> <DataGridTextColumn Header="{x:Static p:Resources.textChanged}" Binding="{Binding Changed}" IsReadOnly="True" Width="0.1*" />
</DataGrid.Columns> </DataGrid.Columns>

View File

@ -298,7 +298,9 @@ namespace ENI2
int year = Int32.Parse(timevalText.Substring(4, 4)); int year = Int32.Parse(timevalText.Substring(4, 4));
thePicker.SelectedDate = new DateTime(year, month, day, 0, 0, 0); thePicker.SelectedDate = new DateTime(year, month, day, 0, 0, 0);
} }
catch (FormatException) { } catch (Exception) {
thePicker.SelectedDate = null;
}
} }
} }

View File

@ -106,6 +106,26 @@ namespace ENI2
} }
} }
public bool HasCriticalInfoMissing(out string messageText)
{
messageText = "";
// Hier haben wir Logik für Spezialfälle, z.B. dass für BRE und BRV bestimmte Meldeklassen gesendet werden *müssen*
if(this.Core.PoC.Equals("DEBRV") || this.Core.PoC.Equals("DEBRE"))
{
foreach(Message aMessage in _messages)
{
if((aMessage.MessageNotificationClass == Message.NotificationClass.NOA_NOD) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "NOA_NOD"; return true; }
if ((aMessage.MessageNotificationClass == Message.NotificationClass.AGNT) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "AGNT"; return true; }
if ((aMessage.MessageNotificationClass == Message.NotificationClass.INFO) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "INFO"; return true; }
if ((aMessage.MessageNotificationClass == Message.NotificationClass.SEC) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "SEC"; return true; }
if ((aMessage.MessageNotificationClass == Message.NotificationClass.TIEFA) && (aMessage.InternalStatus != Message.BSMDStatus.CONFIRMED)) { messageText = "TIEFA"; return true; }
}
}
return false;
}
#endregion #endregion
#region Construction #region Construction

View File

@ -67,6 +67,9 @@ namespace ENI2.DetailViewControls
this.RegisterTextboxChange(this.textBox_AgentPostalCode, Message.NotificationClass.AGNT); this.RegisterTextboxChange(this.textBox_AgentPostalCode, Message.NotificationClass.AGNT);
this.RegisterTextboxChange(this.textBox_AgentStreetAndNumber, Message.NotificationClass.AGNT); this.RegisterTextboxChange(this.textBox_AgentStreetAndNumber, Message.NotificationClass.AGNT);
this.RegisterTextboxChange(this.textBox_AgentCountry, Message.NotificationClass.AGNT); this.RegisterTextboxChange(this.textBox_AgentCountry, Message.NotificationClass.AGNT);
this.buttonSaveTemplate.IsEnabled = DBManager.Instance.GetReportingPartyDict()[App.UserId.Value].IsEditor;
this.buttonDeleteTemplate.IsEnabled = DBManager.Instance.GetReportingPartyDict()[App.UserId.Value].IsEditor;
} }
public override void Initialize() public override void Initialize()
@ -138,8 +141,7 @@ namespace ENI2.DetailViewControls
private void DataGridCallPurposes_DeleteRequested(DatabaseEntity obj) private void DataGridCallPurposes_DeleteRequested(DatabaseEntity obj)
{ {
CallPurpose cp = obj as CallPurpose; if (obj is CallPurpose cp)
if (cp != null)
{ {
// are you sure dialog is in base class // are you sure dialog is in base class
_noa_nod.CallPurposes.Remove(cp); _noa_nod.CallPurposes.Remove(cp);
@ -256,8 +258,7 @@ namespace ENI2.DetailViewControls
private void comboBox_AgentTemplate_SelectionChanged(object sender, SelectionChangedEventArgs e) private void comboBox_AgentTemplate_SelectionChanged(object sender, SelectionChangedEventArgs e)
{ {
Trace.WriteLine("combo selection changed"); Trace.WriteLine("combo selection changed");
AGNT_Template at = this.comboBox_AgentTemplate.SelectedItem as AGNT_Template; if (this.comboBox_AgentTemplate.SelectedItem is AGNT_Template at)
if(at != null)
{ {
this.textBoxTemplateTitle.Text = at.AgentTitle; this.textBoxTemplateTitle.Text = at.AgentTitle;
this.buttonDeleteTemplate.IsEnabled = true; this.buttonDeleteTemplate.IsEnabled = true;

View File

@ -36,8 +36,8 @@
<MinimumRequiredVersion>5.4.0.0</MinimumRequiredVersion> <MinimumRequiredVersion>5.4.0.0</MinimumRequiredVersion>
<CreateWebPageOnPublish>true</CreateWebPageOnPublish> <CreateWebPageOnPublish>true</CreateWebPageOnPublish>
<WebPage>publish.html</WebPage> <WebPage>publish.html</WebPage>
<ApplicationRevision>4</ApplicationRevision> <ApplicationRevision>8</ApplicationRevision>
<ApplicationVersion>7.6.0.%2a</ApplicationVersion> <ApplicationVersion>7.7.0.%2a</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust> <UseApplicationTrust>false</UseApplicationTrust>
<CreateDesktopShortcut>true</CreateDesktopShortcut> <CreateDesktopShortcut>true</CreateDesktopShortcut>
<PublishWizardCompleted>true</PublishWizardCompleted> <PublishWizardCompleted>true</PublishWizardCompleted>

View File

@ -19,7 +19,7 @@ Copyright (c) 2017 schick Informatik
<RowDefinition Height="28" /> <RowDefinition Height="28" />
<RowDefinition Height="28" /> <RowDefinition Height="28" />
<RowDefinition Height="28" /> <RowDefinition Height="28" />
<RowDefinition Height="28" /> <RowDefinition Height="*" />
</Grid.RowDefinitions> </Grid.RowDefinitions>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="1*" /> <ColumnDefinition Width="1*" />
@ -35,6 +35,8 @@ Copyright (c) 2017 schick Informatik
<Label Name="labelPortOfLoading" Grid.Row="4" Grid.Column="0" Content="{x:Static p:Resources.textCargoPortOfLoading}" /> <Label Name="labelPortOfLoading" Grid.Row="4" Grid.Column="0" Content="{x:Static p:Resources.textCargoPortOfLoading}" />
<Label Name="labelPortOfDischarge" Grid.Row="5" Grid.Column="0" Content="{x:Static p:Resources.textCargoPortOfDischarge}" /> <Label Name="labelPortOfDischarge" Grid.Row="5" Grid.Column="0" Content="{x:Static p:Resources.textCargoPortOfDischarge}" />
<Label Name="labelCodeNST3" Grid.Row="1" Grid.Column="2" Content="{x:Static p:Resources.textCargoCodeNST3}" /> <Label Name="labelCodeNST3" Grid.Row="1" Grid.Column="2" Content="{x:Static p:Resources.textCargoCodeNST3}" />
<Label Name="labelSearchNST2007" Grid.Row="3" Grid.Column="2" Content="{x:Static p:Resources.textSearchNST}" HorizontalAlignment="Right" />
<ComboBox Grid.Row="0" Grid.Column="1" Name="comboBoxHandlingType" Margin="2" IsEditable="True" StaysOpenOnEdit="True" IsTextSearchEnabled="True"/> <ComboBox Grid.Row="0" Grid.Column="1" Name="comboBoxHandlingType" Margin="2" IsEditable="True" StaysOpenOnEdit="True" IsTextSearchEnabled="True"/>
<ComboBox Grid.Row="0" Grid.Column="3" Name="comboBoxLACodes" Margin="2" IsEditable="True" SelectedValuePath="Key" DisplayMemberPath="Value" StaysOpenOnEdit="True" IsTextSearchEnabled="True"/> <ComboBox Grid.Row="0" Grid.Column="3" Name="comboBoxLACodes" Margin="2" IsEditable="True" SelectedValuePath="Key" DisplayMemberPath="Value" StaysOpenOnEdit="True" IsTextSearchEnabled="True"/>
@ -43,7 +45,26 @@ Copyright (c) 2017 schick Informatik
<xctk:IntegerUpDown Grid.Row="2" Grid.Column="1" Name="integerUpDownNumberOfItems" ShowButtonSpinner="False" ParsingNumberStyle="Any" Margin="2,2,2,2" TextAlignment="Left"/> <xctk:IntegerUpDown Grid.Row="2" Grid.Column="1" Name="integerUpDownNumberOfItems" ShowButtonSpinner="False" ParsingNumberStyle="Any" Margin="2,2,2,2" TextAlignment="Left"/>
<xctk:DoubleUpDown Grid.Row="3" Grid.Column="1" Name="doubleUpDownGrossQuantity" ShowButtonSpinner="False" ParsingNumberStyle="Any" Margin="2,2,2,2" FormatString="N3" TextAlignment="Left"/> <xctk:DoubleUpDown Grid.Row="3" Grid.Column="1" Name="doubleUpDownGrossQuantity" ShowButtonSpinner="False" ParsingNumberStyle="Any" Margin="2,2,2,2" FormatString="N3" TextAlignment="Left"/>
<enictrl:LocodeControl Grid.Column="1" Grid.Row="4" Width="Auto" x:Name="locodeControl_PortOfLoading" /> <enictrl:LocodeControl Grid.Column="1" Grid.Row="4" Width="Auto" x:Name="locodeControl_PortOfLoading" />
<enictrl:LocodeControl Grid.Column="1" Grid.Row="5" Width="Auto" x:Name="locodeControl_PortOfDischarge" /> <enictrl:LocodeControl Grid.Column="1" Grid.Row="5" Width="Auto" x:Name="locodeControl_PortOfDischarge" Height="28" VerticalAlignment="Top"/>
<TextBox Grid.Row="3" Grid.Column="3" Margin="2" Name="textBoxSearchNSTList" TextChanged="textBoxSearchNSTList_TextChanged" VerticalContentAlignment="Center" />
<Grid Grid.Row="4" Grid.Column="3" Grid.RowSpan="2">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*" />
<ColumnDefinition Width="28" />
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="28" />
<RowDefinition Height="*" />
</Grid.RowDefinitions>
<ListBox Name="listBoxNST2007" Margin="2" Grid.RowSpan="2" DisplayMemberPath="Key" MouseDoubleClick="listBoxNST2007_MouseDoubleClick" />
<!--ComboBox Name="comboBoxSelectNST2007ListItem" Margin="2" DisplayMemberPath="Key" Grid.RowSpan="2" /-->
<Button Name="buttonSetTemplate" Margin="2" Click="buttonSetTemplate_Click" BorderThickness="0" Background="Transparent" ToolTip="Apply template" HorizontalContentAlignment="Right" Grid.Column="1">
<StackPanel Orientation="Horizontal">
<Image Source="../Resources/check.png" Margin="0,0,0,0" Height="20" Width="20" />
</StackPanel>
</Button>
</Grid>
</Grid> </Grid>
</enictrl:EditWindowBase> </enictrl:EditWindowBase>

View File

@ -2,13 +2,14 @@
// Description: LADG Bearbeitungsdialog // Description: LADG Bearbeitungsdialog
// //
using System;
using System.Linq;
using System.Windows; using System.Windows;
using System.Collections.Generic; using System.Collections.Generic;
using bsmd.database; using bsmd.database;
using ENI2.Controls; using ENI2.Controls;
using System.Collections.ObjectModel;
using System.Windows.Data;
namespace ENI2.EditControls namespace ENI2.EditControls
{ {
@ -30,10 +31,14 @@ namespace ENI2.EditControls
Properties.Resources.textDischarge Properties.Resources.textDischarge
}; };
private static List<KeyValuePair<string, string>> _nstList = null;
public EditLADGDialog() public EditLADGDialog()
{ {
InitializeComponent(); InitializeComponent();
Loaded += EditLADGDialog_Loaded; Loaded += EditLADGDialog_Loaded;
if (_nstList == null)
_nstList = LocalizedLookup.GetNST2007List();
} }
public LADG LADG { get; set; } public LADG LADG { get; set; }
@ -112,5 +117,42 @@ namespace ENI2.EditControls
#endregion #endregion
#region NST2007 list search/select event handler
private void textBoxSearchNSTList_TextChanged(object sender, System.Windows.Controls.TextChangedEventArgs e)
{
if (textBoxSearchNSTList.Text.IsNullOrEmpty() || (textBoxSearchNSTList.Text.Length == 1))
{
this.listBoxNST2007.ItemsSource = null;
// this.comboBoxSelectNST2007ListItem.ItemsSource = null;
}
else
{
var result = _nstList.Where(kvp => kvp.Key.Contains(textBoxSearchNSTList.Text, StringComparison.OrdinalIgnoreCase));
this.listBoxNST2007.ItemsSource = result;
//this.comboBoxSelectNST2007ListItem.ItemsSource = result;
}
}
private void buttonSetTemplate_Click(object sender, RoutedEventArgs e)
{
if(this.listBoxNST2007.SelectedItem != null)
{
KeyValuePair<string, string> selectedTemplate = (KeyValuePair<string, string>) this.listBoxNST2007.SelectedItem;
if(selectedTemplate.Value.Length == 3)
{
this.comboBoxNSTCode.SelectedValue = selectedTemplate.Value.Substring(0, 2);
this.comboBoxNST3Code.SelectedValue = selectedTemplate.Value.Substring(2, 1);
}
}
}
private void listBoxNST2007_MouseDoubleClick(object sender, System.Windows.Input.MouseButtonEventArgs e)
{
this.buttonSetTemplate_Click(null, null);
}
#endregion
} }
} }

View File

@ -48,6 +48,7 @@
<Label Name="labelArchived" Grid.Row="8" Grid.Column="0" Content="{x:Static p:Resources.textArchived}" HorizontalContentAlignment="Right" /> <Label Name="labelArchived" Grid.Row="8" Grid.Column="0" Content="{x:Static p:Resources.textArchived}" HorizontalContentAlignment="Right" />
<Label Name="labelCreated" Grid.Row="9" Grid.Column="0" Content="{x:Static p:Resources.textCreated}" HorizontalContentAlignment="Right" /> <Label Name="labelCreated" Grid.Row="9" Grid.Column="0" Content="{x:Static p:Resources.textCreated}" HorizontalContentAlignment="Right" />
<Label Name="labelChanged" Grid.Row="9" Grid.Column="2" Content="{x:Static p:Resources.textChanged}" HorizontalContentAlignment="Right" /> <Label Name="labelChanged" Grid.Row="9" Grid.Column="2" Content="{x:Static p:Resources.textChanged}" HorizontalContentAlignment="Right" />
<Label Name="labelEditor" Grid.Row="8" Grid.Column="2" Content="{x:Static p:Resources.textEditor}" HorizontalContentAlignment="Right" />
<TextBox Grid.Row="0" Grid.Column="1" Width="auto" Name="textBoxName" Margin="2" MaxLength="100" VerticalContentAlignment="Center" /> <TextBox Grid.Row="0" Grid.Column="1" Width="auto" Name="textBoxName" Margin="2" MaxLength="100" VerticalContentAlignment="Center" />
<TextBox Grid.Row="0" Grid.Column="3" Width="auto" Name="textBoxEMail" Margin="2" MaxLength="100" VerticalContentAlignment="Center" /> <TextBox Grid.Row="0" Grid.Column="3" Width="auto" Name="textBoxEMail" Margin="2" MaxLength="100" VerticalContentAlignment="Center" />
@ -64,6 +65,7 @@
<PasswordBox Grid.Row="6" Grid.Column="3" Width="auto" Name="passwordBoxPassword" Margin="2" VerticalContentAlignment="Center" /> <PasswordBox Grid.Row="6" Grid.Column="3" Width="auto" Name="passwordBoxPassword" Margin="2" VerticalContentAlignment="Center" />
<TextBox Grid.Row="7" Grid.Column="1" Width="auto" Name="textBoxUserEMail" Margin="2" MaxLength="100" VerticalContentAlignment="Center" /> <TextBox Grid.Row="7" Grid.Column="1" Width="auto" Name="textBoxUserEMail" Margin="2" MaxLength="100" VerticalContentAlignment="Center" />
<CheckBox Grid.Row="7" Grid.Column="3" VerticalAlignment="Center" Name="checkBoxAdministrator" Margin="2" /> <CheckBox Grid.Row="7" Grid.Column="3" VerticalAlignment="Center" Name="checkBoxAdministrator" Margin="2" />
<CheckBox Grid.Row="8" Grid.Column="3" VerticalAlignment="Center" Name="checkBoxEditor" Margin="2" />
<CheckBox Grid.Row="8" Grid.Column="1" VerticalAlignment="Center" Name="checkBoxArchived" Margin="2" /> <CheckBox Grid.Row="8" Grid.Column="1" VerticalAlignment="Center" Name="checkBoxArchived" Margin="2" />
<Label Grid.Row="9" Grid.Column="1" Name="dateTimePickerCreated" FontStyle="Italic" /> <Label Grid.Row="9" Grid.Column="1" Name="dateTimePickerCreated" FontStyle="Italic" />

View File

@ -39,6 +39,7 @@ namespace ENI2.EditControls
this.checkBoxAdministrator.IsChecked = this.ReportingParty.IsAdmin; this.checkBoxAdministrator.IsChecked = this.ReportingParty.IsAdmin;
this.checkBoxArchived.IsChecked = this.ReportingParty.IsArchived; this.checkBoxArchived.IsChecked = this.ReportingParty.IsArchived;
this.checkBoxEditor.IsChecked = this.ReportingParty.IsEditor;
this.dateTimePickerChanged.Content = this.ReportingParty.Changed.HasValue ? this.ReportingParty.Changed.ToString() : ""; this.dateTimePickerChanged.Content = this.ReportingParty.Changed.HasValue ? this.ReportingParty.Changed.ToString() : "";
this.dateTimePickerCreated.Content = this.ReportingParty.Created.HasValue ? this.ReportingParty.Created.ToString() : ""; this.dateTimePickerCreated.Content = this.ReportingParty.Created.HasValue ? this.ReportingParty.Created.ToString() : "";
@ -69,6 +70,7 @@ namespace ENI2.EditControls
this.ReportingParty.IsAdmin = this.checkBoxAdministrator.IsChecked ?? false; this.ReportingParty.IsAdmin = this.checkBoxAdministrator.IsChecked ?? false;
this.ReportingParty.IsArchived = this.checkBoxArchived.IsChecked ?? false; this.ReportingParty.IsArchived = this.checkBoxArchived.IsChecked ?? false;
this.ReportingParty.IsEditor = this.checkBoxEditor.IsChecked ?? false;
// save value // save value
DBManager.GetSingleCon(Properties.Settings.Default.ConnectionString).Save(this.ReportingParty); DBManager.GetSingleCon(Properties.Settings.Default.ConnectionString).Save(this.ReportingParty);

View File

@ -29,7 +29,7 @@
<Label Name="labelIMO" Grid.Column="1" Grid.Row="2"/> <Label Name="labelIMO" Grid.Column="1" Grid.Row="2"/>
<Label Name="statusLabel" HorizontalAlignment="Center" Content="{x:Static p:Resources.textWaitForId}" Background="LemonChiffon" Grid.Row="3" Grid.ColumnSpan="2"/> <Label Name="statusLabel" HorizontalAlignment="Center" Content="{x:Static p:Resources.textWaitForId}" Background="LemonChiffon" Grid.Row="3" Grid.ColumnSpan="2"/>
<TextBox IsReadOnly="True" Name="textBoxId" MouseDown="textBoxId_MouseDown" FontWeight="Bold" HorizontalAlignment="Center" VerticalContentAlignment="Center" Margin="2" Grid.Row="4" Grid.ColumnSpan="2"/> <TextBox IsReadOnly="True" Name="textBoxId" MouseDown="textBoxId_MouseDown" FontWeight="Bold" HorizontalAlignment="Center" VerticalContentAlignment="Center" Margin="2" Grid.Row="4" Grid.ColumnSpan="2"/>
<Label Name="clickToCopyLabel" Content=" -> click to copy" HorizontalAlignment="Center" Grid.Row="5" Grid.ColumnSpan="2" MouseDown="textBoxId_MouseDown" Visibility="Hidden"/> <Button Name="clickToCopyButton" Content=" -&gt; click to copy &lt;- " HorizontalAlignment="Center" Grid.Row="5" Grid.ColumnSpan="2" Click="clickToCopyButton_Click" Visibility="Hidden" Margin="2"/>
<Button Grid.Row="6" Grid.Column="0" HorizontalAlignment="Left" Content="Close and open Id" Margin="2" Width="100" Click="Button_Click_1" /> <Button Grid.Row="6" Grid.Column="0" HorizontalAlignment="Left" Content="Close and open Id" Margin="2" Width="100" Click="Button_Click_1" />
<Button Grid.Row="6" Grid.Column="1" HorizontalAlignment="Right" Content="Close" Margin="2" Width="100" Click="Button_Click" /> <Button Grid.Row="6" Grid.Column="1" HorizontalAlignment="Right" Content="Close" Margin="2" Width="100" Click="Button_Click" />
</Grid> </Grid>

View File

@ -38,15 +38,10 @@ namespace ENI2.EditControls
this.DisplayId = id; this.DisplayId = id;
this.statusLabel.Content = Properties.Resources.textIdReceived; this.statusLabel.Content = Properties.Resources.textIdReceived;
this.statusLabel.Background = Brushes.LightGreen; this.statusLabel.Background = Brushes.LightGreen;
this.clickToCopyLabel.Visibility = Visibility.Visible; this.clickToCopyButton.Visibility = Visibility.Visible;
})); }));
} }
private void textBoxId_MouseDown(object sender, MouseButtonEventArgs e)
{
Clipboard.SetText(this.textBoxId.Text);
}
private void Button_Click(object sender, RoutedEventArgs e) private void Button_Click(object sender, RoutedEventArgs e)
{ {
this.Close(); this.Close();
@ -67,5 +62,16 @@ namespace ENI2.EditControls
this.labelIMO.Content = this.Core.IMO.IsNullOrEmpty() ? this.Core.ENI : this.Core.IMO; this.labelIMO.Content = this.Core.IMO.IsNullOrEmpty() ? this.Core.ENI : this.Core.IMO;
} }
} }
private void clickToCopyButton_Click(object sender, RoutedEventArgs e)
{
Clipboard.SetText(this.textBoxId.Text);
this.clickToCopyButton.Background = Brushes.LightGreen;
}
private void textBoxId_MouseDown(object sender, MouseButtonEventArgs e)
{
Clipboard.SetText(this.textBoxId.Text);
}
} }
} }

View File

@ -7,27 +7,25 @@
// //
// Copyright (c) 2015 Informatikbüro Daniel Schick. All rights reserved. // Copyright (c) 2015 Informatikbüro Daniel Schick. All rights reserved.
using log4net; using bsmd.database;
using ENI2.Locode;
using Microsoft.Office.Interop.Excel; using Microsoft.Office.Interop.Excel;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Data; using System.Data;
using System.Globalization; using System.Globalization;
using System.Linq; using System.Linq;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
using ENI2.Locode;
using bsmd.database;
using System.Text.RegularExpressions;
namespace ENI2.Excel namespace ENI2.Excel
{ {
internal class ExcelReader : ExcelBase internal class ExcelReader : ExcelBase
{ {
internal enum ReadState
{ NONE, OK, WARN, FAIL };
internal enum ReadState { NONE, OK, WARN, FAIL }; internal enum SheetTypeEnum
{ BSMD, DAKOSY };
internal enum SheetTypeEnum { BSMD, DAKOSY };
private readonly SheetTypeEnum _sheetType = SheetTypeEnum.BSMD; private readonly SheetTypeEnum _sheetType = SheetTypeEnum.BSMD;
@ -44,7 +42,8 @@ namespace ENI2.Excel
_sheetType = (_nameDict.Count > 10) ? SheetTypeEnum.BSMD : SheetTypeEnum.DAKOSY; _sheetType = (_nameDict.Count > 10) ? SheetTypeEnum.BSMD : SheetTypeEnum.DAKOSY;
} }
public SheetTypeEnum SheetType { get { return _sheetType; } } public SheetTypeEnum SheetType
{ get { return _sheetType; } }
internal static void SaveMessage(Message message) internal static void SaveMessage(Message message)
{ {
@ -154,7 +153,8 @@ namespace ENI2.Excel
string val = this.ReadText(lookup); string val = this.ReadText(lookup);
if (val != null) if (val != null)
{ {
if (val.Equals("m", StringComparison.CurrentCultureIgnoreCase) || val.Equals("male", StringComparison.CurrentCultureIgnoreCase)) { if (val.Equals("m", StringComparison.CurrentCultureIgnoreCase) || val.Equals("male", StringComparison.CurrentCultureIgnoreCase))
{
result = 1; result = 1;
} }
else if (val.Equals("f", StringComparison.CurrentCultureIgnoreCase) || val.Equals("female", StringComparison.CurrentCultureIgnoreCase)) else if (val.Equals("f", StringComparison.CurrentCultureIgnoreCase) || val.Equals("female", StringComparison.CurrentCultureIgnoreCase))
@ -446,6 +446,21 @@ namespace ENI2.Excel
date = tmpDate; date = tmpDate;
} }
if (date == null)
{
string[] formats = { "d/M/yyyy", "dd/M/yyyy", "d/MM/yyyy", "dd/MM/yyyy", "d/MMM/yyyy", "dd/MMM/yyyy", "yyyy-MM-dd", "yyyy-mm-d", "dd-MM-yyyy" };
if (DateTime.TryParseExact(val, formats, NumberFormatInfo.InvariantInfo, DateTimeStyles.None, out DateTime tmpDate))
date = tmpDate;
}
if (date == null)
{
CultureInfo en = CultureInfo.CreateSpecificCulture("en-US");
string[] formats = { "d/M/yyyy", "dd/M/yyyy", "d/MM/yyyy", "dd/MM/yyyy", "d/MMM/yyyy", "dd/MMM/yyyy", "yyyy-MM-dd", "yyyy-mm-d", "dd-MM-yyyy" };
if (DateTime.TryParseExact(val, formats, en, DateTimeStyles.None, out DateTime tmpDate))
return tmpDate;
}
if (date != null) if (date != null)
{ {
if ((date.Value < new DateTime(1899, 1, 1)) || (date.Value > new DateTime(2130, 1, 1))) if ((date.Value < new DateTime(1899, 1, 1)) || (date.Value > new DateTime(2130, 1, 1)))
@ -520,7 +535,8 @@ namespace ENI2.Excel
} }
} }
if (val is string) { if (val is string)
{
if (((string)val).EndsWith("lt", StringComparison.OrdinalIgnoreCase)) if (((string)val).EndsWith("lt", StringComparison.OrdinalIgnoreCase))
val = ((string)val).Substring(0, ((string)val).Length - 2).Trim(); val = ((string)val).Substring(0, ((string)val).Length - 2).Trim();
else else
@ -584,6 +600,19 @@ namespace ENI2.Excel
#region Dakosy-specific functions #region Dakosy-specific functions
internal bool HasWorksheetNamed(string sheetName)
{
try
{
Worksheet theWorkSheet = _workBook.Worksheets[sheetName];
return theWorkSheet != null;
}
catch (Exception)
{
return false;
}
}
internal string ReadCellAsText(string sheetName, string range) internal string ReadCellAsText(string sheetName, string range)
{ {
try try
@ -627,7 +656,6 @@ namespace ENI2.Excel
Range aRange = workSheet.Range[range]; Range aRange = workSheet.Range[range];
if (aRange != null) if (aRange != null)
{ {
} }
} }
catch (Exception e) catch (Exception e)
@ -690,23 +718,19 @@ namespace ENI2.Excel
string dateString = ReadCellAsText(sheetName, range); string dateString = ReadCellAsText(sheetName, range);
if (dateString != null) if (dateString != null)
{ {
CultureInfo provider = CultureInfo.InvariantCulture; string[] formats = { "yyyy/MM/dd HH:mm", "yyyy/MM/dd", "dd.MM.yyyy", "dd-MM-yyyy", "d/M/yyyy", "dd/M/yyyy", "d/MM/yyyy", "dd/MM/yyyy", "d/MMM/yyyy", "dd/MMM/yyyy", "yyyy-MM-dd", "yyyy-mm-d" };
const string dateTimeFormat = "yyyy/MM/dd HH:mm"; if (DateTime.TryParseExact(dateString, formats, NumberFormatInfo.InvariantInfo, DateTimeStyles.None, out DateTime tmpDate))
if (DateTime.TryParseExact(dateString, dateTimeFormat, provider, DateTimeStyles.None, out DateTime tmpDate)) return tmpDate;
return tmpDate.ToUniversalTime(); CultureInfo en = CultureInfo.CreateSpecificCulture("en-US");
const string dateFormat = "yyyy/MM/dd"; if (DateTime.TryParseExact(dateString, formats, en, DateTimeStyles.None, out DateTime tmpDate2))
if (DateTime.TryParseExact(dateString, dateFormat, provider, DateTimeStyles.None, out DateTime tmpDate2))
return tmpDate2; return tmpDate2;
const string dateFormat2 = "dd.MM.yyyy";
if (DateTime.TryParseExact(dateString, dateFormat2, provider, DateTimeStyles.None, out DateTime tmpDate3))
return tmpDate3;
return null; return null;
} }
else return null; else
return null;
} }
#endregion #endregion Dakosy-specific functions
} }
} }

View File

@ -7,14 +7,14 @@
// //
// Copyright (c) 2015 Informatikbüro Daniel Schick. All rights reserved. // Copyright (c) 2015 Informatikbüro Daniel Schick. All rights reserved.
using bsmd.database;
using ENI2.EditControls;
using ENI2.Locode;
using log4net;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq; using System.Linq;
using System.Reflection; using System.Reflection;
using log4net;
using bsmd.database;
using ENI2.Locode;
using ENI2.EditControls;
namespace ENI2.Excel namespace ENI2.Excel
{ {
@ -67,7 +67,6 @@ namespace ENI2.Excel
// parse selected classes // parse selected classes
try try
{ {
foreach (Message message in messages) foreach (Message message in messages)
{ {
if ((message.MessageNotificationClass == Message.NotificationClass.AGNT) && notificationClasses.Contains(Message.NotificationClass.AGNT)) if ((message.MessageNotificationClass == Message.NotificationClass.AGNT) && notificationClasses.Contains(Message.NotificationClass.AGNT))
@ -130,7 +129,6 @@ namespace ENI2.Excel
{ if (ScanWAS(message, reader, isOldVersion)) ExcelReader.SaveMessage(message); continue; } { if (ScanWAS(message, reader, isOldVersion)) ExcelReader.SaveMessage(message); continue; }
if ((message.MessageNotificationClass == Message.NotificationClass.WAS_RCPT) && notificationClasses.Contains(Message.NotificationClass.WAS_RCPT)) if ((message.MessageNotificationClass == Message.NotificationClass.WAS_RCPT) && notificationClasses.Contains(Message.NotificationClass.WAS_RCPT))
{ if (ScanWAS_RCPT(message, reader)) ExcelReader.SaveMessage(message); continue; } { if (ScanWAS_RCPT(message, reader)) ExcelReader.SaveMessage(message); continue; }
} }
DBManager.Instance.Save(messageCore); // muss das eigentlich sein? DBManager.Instance.Save(messageCore); // muss das eigentlich sein?
@ -144,7 +142,7 @@ namespace ENI2.Excel
return result; return result;
} }
#endregion #endregion Process Sheet (normal BSMD sheet import)
#region ATA #region ATA
@ -167,7 +165,7 @@ namespace ENI2.Excel
return !(!ata.ATAPortOfCall.HasValue && ataMessage.IsNew); return !(!ata.ATAPortOfCall.HasValue && ataMessage.IsNew);
} }
#endregion #endregion ATA
#region ATD #region ATD
@ -190,7 +188,7 @@ namespace ENI2.Excel
return !(!atd.ATDPortOfCall.HasValue && atdMessage.IsNew); return !(!atd.ATDPortOfCall.HasValue && atdMessage.IsNew);
} }
#endregion #endregion ATD
#region TIEFA #region TIEFA
@ -211,7 +209,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion TIEFA
#region TIEFD #region TIEFD
@ -232,7 +230,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion TIEFD
#region NAME #region NAME
@ -251,7 +249,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion NAME
#region BPOL #region BPOL
@ -313,7 +311,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion BPOL
#region POBA #region POBA
@ -331,10 +329,13 @@ namespace ENI2.Excel
if (((poba.TotalPersonsOnBoardUponArrival ?? 0) == 0) && poba.IsNew) if (((poba.TotalPersonsOnBoardUponArrival ?? 0) == 0) && poba.IsNew)
return false; return false;
if (!poba.TotalPassengersOnBoardUponArrival.HasValue) poba.TotalPassengersOnBoardUponArrival = 0;
if (!poba.TotalStowawaysOnBoardUponArrival.HasValue) poba.TotalStowawaysOnBoardUponArrival = 0;
return true; return true;
} }
#endregion #endregion POBA
#region POBD #region POBD
@ -352,16 +353,18 @@ namespace ENI2.Excel
if (((pobd.TotalPersonsOnBoardUponDeparture ?? 0) == 0) && pobd.IsNew) if (((pobd.TotalPersonsOnBoardUponDeparture ?? 0) == 0) && pobd.IsNew)
return false; return false;
if (!pobd.TotalPassengersOnBoardUponDeparture.HasValue) pobd.TotalPassengersOnBoardUponDeparture = 0;
if (!pobd.TotalStowawaysOnBoardUponDeparture.HasValue) pobd.TotalStowawaysOnBoardUponDeparture = 0;
return true; return true;
} }
#endregion #endregion POBD
#region HAZA #region HAZA
private static bool ScanHAZA(Message hazaMessage, ExcelReader reader, bool isOldVersion) private static bool ScanHAZA(Message hazaMessage, ExcelReader reader, bool isOldVersion)
{ {
if (hazaMessage.Elements.Count == 0) if (hazaMessage.Elements.Count == 0)
{ {
HAZ newHaza = new HAZ(); HAZ newHaza = new HAZ();
@ -443,7 +446,7 @@ namespace ENI2.Excel
imdgPosition.Remarks = reader.ReadText(imdg_remarks); imdgPosition.Remarks = reader.ReadText(imdg_remarks);
} }
#endregion #endregion IMDG
#region IBC #region IBC
@ -508,7 +511,7 @@ namespace ENI2.Excel
ibcPosition.Remarks = reader.ReadText(ibc_remarks); ibcPosition.Remarks = reader.ReadText(ibc_remarks);
} }
#endregion #endregion IBC
#region IGC #region IGC
@ -546,7 +549,7 @@ namespace ENI2.Excel
igcPosition.Remarks = reader.ReadText(igc_remarks); igcPosition.Remarks = reader.ReadText(igc_remarks);
} }
#endregion #endregion IGC
#region IMSBC #region IMSBC
@ -588,7 +591,7 @@ namespace ENI2.Excel
imsbcPosition.Remarks = reader.ReadText(imsbc_remarks); imsbcPosition.Remarks = reader.ReadText(imsbc_remarks);
} }
#endregion #endregion IMSBC
#region MARPOL #region MARPOL
@ -637,7 +640,7 @@ namespace ENI2.Excel
marpolPosition.Remarks = reader.ReadText(marpol_remarks); marpolPosition.Remarks = reader.ReadText(marpol_remarks);
} }
#endregion #endregion MARPOL
if (haza.HasPositions) // Christin 22.3.17: Felder bei Positionen immer fest ausfüllen if (haza.HasPositions) // Christin 22.3.17: Felder bei Positionen immer fest ausfüllen
{ {
@ -647,7 +650,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion HAZA
#region HAZD #region HAZD
@ -731,7 +734,7 @@ namespace ENI2.Excel
imdgPosition.Remarks = reader.ReadText(imdg_remarks); imdgPosition.Remarks = reader.ReadText(imdg_remarks);
} }
#endregion #endregion IMDG
#region IBC #region IBC
@ -794,7 +797,7 @@ namespace ENI2.Excel
ibcPosition.Remarks = reader.ReadText(ibc_remarks); ibcPosition.Remarks = reader.ReadText(ibc_remarks);
} }
#endregion #endregion IBC
#region IGC #region IGC
@ -832,7 +835,7 @@ namespace ENI2.Excel
igcPosition.Remarks = reader.ReadText(igc_remarks); igcPosition.Remarks = reader.ReadText(igc_remarks);
} }
#endregion #endregion IGC
#region IMSBC #region IMSBC
@ -874,7 +877,7 @@ namespace ENI2.Excel
imsbcPosition.Remarks = reader.ReadText(imsbc_remarks); imsbcPosition.Remarks = reader.ReadText(imsbc_remarks);
} }
#endregion #endregion IMSBC
#region MARPOL #region MARPOL
@ -903,7 +906,8 @@ namespace ENI2.Excel
marpolPosition.Name = name; marpolPosition.Name = name;
marpolPosition.Flashpoint_CEL = reader.ReadText(marpol_flash); marpolPosition.Flashpoint_CEL = reader.ReadText(marpol_flash);
if (marpolPosition.Flashpoint_CEL.IsNullOrEmpty()) { if (marpolPosition.Flashpoint_CEL.IsNullOrEmpty())
{
marpolPosition.FlashpointInformation = 0; marpolPosition.FlashpointInformation = 0;
} // NF // Ableitung Flashpoint-Info: Christin, 22.3.2017 } // NF // Ableitung Flashpoint-Info: Christin, 22.3.2017
else else
@ -922,7 +926,7 @@ namespace ENI2.Excel
marpolPosition.Remarks = reader.ReadText(marpol_remarks); marpolPosition.Remarks = reader.ReadText(marpol_remarks);
} }
#endregion #endregion MARPOL
if (hazd.HasPositions) // Christin 22.3.17: Felder bei Positionen immer fest ausfüllen if (hazd.HasPositions) // Christin 22.3.17: Felder bei Positionen immer fest ausfüllen
{ {
@ -932,7 +936,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion HAZD
#region INFO #region INFO
@ -960,7 +964,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion INFO
#region STAT #region STAT
@ -1001,7 +1005,8 @@ namespace ENI2.Excel
if (stat.ISMCompanyId.StartsWith("imo", StringComparison.OrdinalIgnoreCase)) if (stat.ISMCompanyId.StartsWith("imo", StringComparison.OrdinalIgnoreCase))
stat.ISMCompanyId = stat.ISMCompanyId.Substring(3); stat.ISMCompanyId = stat.ISMCompanyId.Substring(3);
if(stat.ISMCompanyId.Length < 7) { // zero - fill if (stat.ISMCompanyId.Length < 7)
{ // zero - fill
while (stat.ISMCompanyId.Length < 7) while (stat.ISMCompanyId.Length < 7)
stat.ISMCompanyId = "0" + stat.ISMCompanyId; stat.ISMCompanyId = "0" + stat.ISMCompanyId;
} }
@ -1023,7 +1028,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion STAT
#region NOA_NOD #region NOA_NOD
@ -1059,7 +1064,6 @@ namespace ENI2.Excel
if (!callPurposeCode.IsNullOrEmpty()) if (!callPurposeCode.IsNullOrEmpty())
{ {
if (!(noa_nod.GetSublistElementWithIdentifier(i.ToString()) is CallPurpose callPurpose)) if (!(noa_nod.GetSublistElementWithIdentifier(i.ToString()) is CallPurpose callPurpose))
{ {
callPurpose = new CallPurpose(); callPurpose = new CallPurpose();
@ -1114,7 +1118,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion NOA_NOD
#region AGNT #region AGNT
@ -1135,7 +1139,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion AGNT
#region WAS #region WAS
@ -1261,7 +1265,8 @@ namespace ENI2.Excel
was.AddMissingWaste(); was.AddMissingWaste();
return true; return true;
} }
#endregion
#endregion WAS
#region WAS_RCPT #region WAS_RCPT
@ -1339,7 +1344,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion WAS_RCPT
#region MDH #region MDH
@ -1364,7 +1369,6 @@ namespace ENI2.Excel
try try
{ {
#region PoC last 30 days #region PoC last 30 days
// lt. Mail von Christin am 11.10.2016 // lt. Mail von Christin am 11.10.2016
@ -1396,7 +1400,6 @@ namespace ENI2.Excel
} }
else // "normal mode", aus den Zellen lesen else // "normal mode", aus den Zellen lesen
{ {
// POC last 30 days // POC last 30 days
for (int i = 0; i < mdh.NumberOfExcelRows; i++) for (int i = 0; i < mdh.NumberOfExcelRows; i++)
{ {
@ -1454,7 +1457,7 @@ namespace ENI2.Excel
} }
} }
#endregion #endregion PoC last 30 days
#region SanitaryMeasures #region SanitaryMeasures
@ -1484,7 +1487,7 @@ namespace ENI2.Excel
} }
} }
#endregion #endregion SanitaryMeasures
#region InfectedArea #region InfectedArea
@ -1511,7 +1514,7 @@ namespace ENI2.Excel
} }
} }
#endregion #endregion InfectedArea
#region StowawaysJoiningLocation #region StowawaysJoiningLocation
@ -1537,8 +1540,7 @@ namespace ENI2.Excel
} }
} }
#endregion #endregion StowawaysJoiningLocation
} }
catch (Exception ex) catch (Exception ex)
{ {
@ -1550,7 +1552,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion MDH
#region SEC #region SEC
@ -1662,7 +1664,6 @@ namespace ENI2.Excel
// keinen "leeren" Hafen anlegen, wenn der Eintrag leer war (trifft anscheinend bei Neubauten zu, siehe E-Mail Christin vom 20./22.6.17 // keinen "leeren" Hafen anlegen, wenn der Eintrag leer war (trifft anscheinend bei Neubauten zu, siehe E-Mail Christin vom 20./22.6.17
if (l10fc.PortFacilityPortName.IsNullOrEmpty() && l10fc.PortFacilityPortLoCode.IsNullOrEmpty() && l10fc.PortFacilityPortCountry.IsNullOrEmpty()) if (l10fc.PortFacilityPortName.IsNullOrEmpty() && l10fc.PortFacilityPortLoCode.IsNullOrEmpty() && l10fc.PortFacilityPortCountry.IsNullOrEmpty())
sec.LastTenPortFacilitesCalled.Remove(l10fc); sec.LastTenPortFacilitesCalled.Remove(l10fc);
} }
// Ship2ShipActivities // Ship2ShipActivities
@ -1711,7 +1712,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion SEC
#region BKRA #region BKRA
@ -1741,7 +1742,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion BKRA
#region BKRD #region BKRD
@ -1770,7 +1771,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion BKRD
#region TOWA #region TOWA
@ -1828,13 +1829,12 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion TOWA
#region TOWD #region TOWD
private static bool ScanTOWD(Message towdMessage, ExcelReader reader) private static bool ScanTOWD(Message towdMessage, ExcelReader reader)
{ {
// 24.4.21: TOWD beim Excel import // 24.4.21: TOWD beim Excel import
bool hasTOWDMarker = false; bool hasTOWDMarker = false;
for (int i = 1; i <= towdMessage.NumberOfExcelRows; i++) for (int i = 1; i <= towdMessage.NumberOfExcelRows; i++)
@ -1886,7 +1886,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion TOWD
#region PRE72H #region PRE72H
@ -1908,7 +1908,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion PRE72H
#region SERV #region SERV
@ -1929,7 +1929,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion SERV
#region STO #region STO
@ -1967,7 +1967,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion STO
#region LADG #region LADG
@ -2054,23 +2054,24 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion LADG
#region CREW #region CREW
private static bool ScanCREW(Message crewMessage, ExcelReader reader, bool isOldVersion) private static bool ScanCREW(Message crewMessage, ExcelReader reader, bool isOldVersion)
{ {
crewMessage.DeleteElements(); crewMessage.DeleteElements();
string sheetTitle = "6. CREW - Arrival"; string sheetTitle = "6. CREW - Arrival";
// 6. CREW - Arrival // 6. CREW - Arrival
// 5.9.22: Changed this area to work like reading from a Dakosy Sheet (by values in rows, not cell names) // 5.9.22: Changed this area to work like reading from a Dakosy Sheet (by values in rows, not cell names)
if (reader.HasWorksheetNamed(sheetTitle))
{
bool? notificationSchengen = reader.ReadBoolean("CREW.NotificationSchengen"); bool? notificationSchengen = reader.ReadBoolean("CREW.NotificationSchengen");
bool? notificationPax = reader.ReadBoolean("CREW.NotificationPAX"); bool? notificationPax = reader.ReadBoolean("CREW.NotificationPAX");
for (int i = 0; i < 5000; i++) for (int i = 0; i < 5000; i++)
{ {
string lastName = reader.ReadCellAsText(sheetTitle, string.Format("C{0}", i + 18)); string lastName = reader.ReadCellAsText(sheetTitle, string.Format("C{0}", i + 18));
string firstName = reader.ReadCellAsText(sheetTitle, string.Format("D{0}", i + 18)); string firstName = reader.ReadCellAsText(sheetTitle, string.Format("D{0}", i + 18));
if (lastName.IsNullOrEmpty() && firstName.IsNullOrEmpty()) break; if (lastName.IsNullOrEmpty() && firstName.IsNullOrEmpty()) break;
@ -2118,6 +2119,54 @@ namespace ENI2.Excel
Util.UIHelper.SetBusyState(); // dialog might reset busy state Util.UIHelper.SetBusyState(); // dialog might reset busy state
} }
}
else
{
sheetTitle = "5. CREW - Arrival"; // altes Anmeldeformat
if (reader.HasWorksheetNamed(sheetTitle))
{
for (int i = 0; i < 5000; i++)
{
string lastName = reader.ReadCellAsText(sheetTitle, string.Format("C{0}", i + 13));
string firstName = reader.ReadCellAsText(sheetTitle, string.Format("D{0}", i + 13));
if (lastName.IsNullOrEmpty() && firstName.IsNullOrEmpty()) break;
if (!(crewMessage.GetSublistElementWithIdentifier((i + 1).ToString()) is CREW crew))
{
crew = new CREW();
crew.Identifier = (i + 1).ToString();
crew.MessageHeader = crewMessage;
crewMessage.Elements.Add(crew);
}
crew.CrewMemberLastName = lastName;
crew.CrewMemberFirstName = firstName;
crew.CrewMemberGender = ReadGender(reader.ReadCellAsText(sheetTitle, string.Format("E{0}", i + 13)), out bool canceled);
if (canceled) return true;
crew.CrewMemberDuty = reader.ReadCellAsText(sheetTitle, string.Format("G{0}", i + 13));
crew.CrewMemberNationality = ReadNationality(reader.ReadCellAsText(sheetTitle, string.Format("F{0}", i + 13)), out canceled);
if (canceled) return true;
crew.CrewMemberPlaceOfBirth = reader.ReadCellAsText(sheetTitle, string.Format("H{0}", i + 13));
crew.CrewMemberDateOfBirth = reader.ReadCellAsDateTime(sheetTitle, string.Format("I{0}", i + 13));
crew.CrewMemberIdentityDocumentType = ReadDocumentType(reader.ReadCellAsText(sheetTitle, string.Format("J{0}", i + 13)), out canceled);
if (canceled) return true;
crew.CrewMemberIdentityDocumentIssuingState = "XX";
crew.CrewMemberIdentityDocumentExpiryDate = new DateTime(2100, 12, 31);
crew.CrewMemberIdentityDocumentId = reader.ReadCellAsText(sheetTitle, string.Format("K{0}", i + 13));
crew.CrewMemberVisaNumber = reader.ReadCellAsText(sheetTitle, string.Format("L{0}", i + 13));
Util.UIHelper.SetBusyState(); // dialog might reset busy state
}
}
else
{
return false; // nothing found
}
}
return true; return true;
} }
@ -2127,13 +2176,13 @@ namespace ENI2.Excel
crewdMessage.DeleteElements(); crewdMessage.DeleteElements();
string sheetTitle = "7. CREW - Departure"; string sheetTitle = "7. CREW - Departure";
// CREW DEPARTURE // CREW DEPARTURE
if (reader.HasWorksheetNamed(sheetTitle))
{
bool? notificationSchengen = reader.ReadBoolean("CREWD.NotificationSchengen"); bool? notificationSchengen = reader.ReadBoolean("CREWD.NotificationSchengen");
bool? notificationPax = reader.ReadBoolean("CREWD.NotificationPAX"); bool? notificationPax = reader.ReadBoolean("CREWD.NotificationPAX");
for (int i = 0; i < 5000; i++) for (int i = 0; i < 5000; i++)
{ {
string lastName = reader.ReadCellAsText(sheetTitle, string.Format("C{0}", i + 18)); string lastName = reader.ReadCellAsText(sheetTitle, string.Format("C{0}", i + 18));
if (lastName.IsNullOrEmpty()) break; if (lastName.IsNullOrEmpty()) break;
@ -2175,32 +2224,81 @@ namespace ENI2.Excel
crewd.CrewMemberIdentityDocumentExpiryDate = new DateTime(2100, 12, 31); crewd.CrewMemberIdentityDocumentExpiryDate = new DateTime(2100, 12, 31);
crewd.Effects = reader.ReadCellAsText("2. PORT", string.Format("C{0}", i + 142)); crewd.Effects = reader.ReadCellAsText("2. PORT", string.Format("C{0}", i + 142));
Util.UIHelper.SetBusyState(); // dialog might reset busy state
} }
}
else
{
sheetTitle = "6. CREW - Departure"; // altes Anmeldeformat
if (reader.HasWorksheetNamed(sheetTitle))
{
for (int i = 0; i < 5000; i++)
{
string lastName = reader.ReadCellAsText(sheetTitle, string.Format("C{0}", i + 13));
if (lastName.IsNullOrEmpty()) break;
if (!(crewdMessage.GetSublistElementWithIdentifier((i + 1).ToString()) is CREWD crewd))
{
crewd = new CREWD();
crewd.Identifier = (i + 1).ToString();
crewd.MessageHeader = crewdMessage;
crewdMessage.Elements.Add(crewd);
}
crewd.CrewMemberLastName = lastName;
crewd.CrewMemberFirstName = reader.ReadCellAsText(sheetTitle, string.Format("D{0}", i + 13));
crewd.CrewMemberGender = ReadGender(reader.ReadCellAsText(sheetTitle, string.Format("E{0}", i + 13)), out bool canceled);
if (canceled) return true;
crewd.CrewMemberDuty = reader.ReadCellAsText(sheetTitle, string.Format("G{0}", i + 13));
crewd.CrewMemberNationality = ReadNationality(reader.ReadCellAsText(sheetTitle, string.Format("F{0}", i + 13)), out canceled);
if (canceled) return true;
crewd.CrewMemberPlaceOfBirth = reader.ReadCellAsText(sheetTitle, string.Format("H{0}", i + 13));
crewd.CrewMemberDateOfBirth = reader.ReadCellAsDateTime(sheetTitle, string.Format("I{0}", i + 13));
crewd.CrewMemberIdentityDocumentType = ReadDocumentType(reader.ReadCellAsText(sheetTitle, string.Format("J{0}", i + 13)), out canceled);
if (canceled) return true;
crewd.CrewMemberIdentityDocumentIssuingState = "XX";
crewd.CrewMemberIdentityDocumentExpiryDate = new DateTime(2100, 12, 31);
crewd.CrewMemberIdentityDocumentId = reader.ReadCellAsText(sheetTitle, string.Format("K{0}", i + 13));
crewd.CrewMemberVisaNumber = reader.ReadCellAsText(sheetTitle, string.Format("L{0}", i + 13));
Util.UIHelper.SetBusyState(); // dialog might reset busy state
}
}
else
{
return false; // nothing found
}
}
return true; return true;
} }
#endregion #endregion CREW
#region PAS #region PAS
private static bool ScanPAS(Message pasMessage, ExcelReader reader, bool isOldVersion) private static bool ScanPAS(Message pasMessage, ExcelReader reader, bool isOldVersion)
{ {
List<PAS> newPasList = new List<PAS>(); List<PAS> newPasList = new List<PAS>();
string sheetTitle = "8. PAX - Arrival"; string sheetTitle = "8. PAX - Arrival";
if (reader.HasWorksheetNamed(sheetTitle))
{
bool? notificationSchengen = reader.ReadBoolean("PAS.NotificationSchengen"); bool? notificationSchengen = reader.ReadBoolean("PAS.NotificationSchengen");
bool? notificationPax = reader.ReadBoolean("PAS.NotificationPAX"); bool? notificationPax = reader.ReadBoolean("PAS.NotificationPAX");
for (int i = 0; i < 5000; i++) for (int i = 0; i < 5000; i++)
{ {
string lastName = reader.ReadCellAsText(sheetTitle, string.Format("C{0}", i + 17)); string lastName = reader.ReadCellAsText(sheetTitle, string.Format("C{0}", i + 17));
string firstName = reader.ReadCellAsText(sheetTitle, string.Format("D{0}", i + 17)); string firstName = reader.ReadCellAsText(sheetTitle, string.Format("D{0}", i + 17));
if (lastName.IsNullOrEmpty() && firstName.IsNullOrEmpty()) break; // finish after reading last row if (lastName.IsNullOrEmpty() && firstName.IsNullOrEmpty()) break; // finish after reading last row
DateTime? dateOfBirth = reader.ReadCellAsDateTime(sheetTitle, string.Format("L{0}", i + 17));
PAS pas = new PAS(); PAS pas = new PAS();
pas.Identifier = (i + 1).ToString(); pas.Identifier = (i + 1).ToString();
pas.MessageHeader = pasMessage; pas.MessageHeader = pasMessage;
@ -2215,7 +2313,8 @@ namespace ENI2.Excel
if (canceled) return true; if (canceled) return true;
pas.PassengerIdentityDocumentIssuingState = ReadNationality(reader.ReadCellAsText(sheetTitle, string.Format("O{0}", i + 17)), out canceled); pas.PassengerIdentityDocumentIssuingState = ReadNationality(reader.ReadCellAsText(sheetTitle, string.Format("O{0}", i + 17)), out canceled);
if (canceled) return true; if (canceled) return true;
if (pas.PassengerIdentityDocumentIssuingState == null) return true; if (pas.PassengerIdentityDocumentIssuingState.IsNullOrEmpty())
pas.PassengerIdentityDocumentIssuingState = "XX";
pas.PassengerGender = ReadGender(reader.ReadCellAsText(sheetTitle, string.Format("E{0}", i + 17)), out canceled); pas.PassengerGender = ReadGender(reader.ReadCellAsText(sheetTitle, string.Format("E{0}", i + 17)), out canceled);
if (canceled) return true; if (canceled) return true;
@ -2229,6 +2328,7 @@ namespace ENI2.Excel
pas.PassengerPlaceOfBirth = reader.ReadCellAsText(sheetTitle, string.Format("J{0}", i + 17)); pas.PassengerPlaceOfBirth = reader.ReadCellAsText(sheetTitle, string.Format("J{0}", i + 17));
pas.PassengerCountryOfBirth = ReadNationality(reader.ReadCellAsText(sheetTitle, string.Format("K{0}", i + 17)), out canceled); pas.PassengerCountryOfBirth = ReadNationality(reader.ReadCellAsText(sheetTitle, string.Format("K{0}", i + 17)), out canceled);
if (canceled) return true; if (canceled) return true;
DateTime? dateOfBirth = reader.ReadCellAsDateTime(sheetTitle, string.Format("L{0}", i + 17));
pas.PassengerDateOfBirth = dateOfBirth; pas.PassengerDateOfBirth = dateOfBirth;
pas.PassengerIdentityDocumentType = ReadDocumentType(reader.ReadCellAsText(sheetTitle, string.Format("M{0}", i + 17)), out canceled); pas.PassengerIdentityDocumentType = ReadDocumentType(reader.ReadCellAsText(sheetTitle, string.Format("M{0}", i + 17)), out canceled);
@ -2244,8 +2344,60 @@ namespace ENI2.Excel
pas.EmergencyContactNumber = reader.ReadCellAsText(sheetTitle, string.Format("S{0}", i + 17)); pas.EmergencyContactNumber = reader.ReadCellAsText(sheetTitle, string.Format("S{0}", i + 17));
Util.UIHelper.SetBusyState(); // dialog might reset busy state Util.UIHelper.SetBusyState(); // dialog might reset busy state
} }
}
else
{
sheetTitle = "7. PAX - Arrival"; // altes Excel Format
if (reader.HasWorksheetNamed(sheetTitle))
{
for (int i = 0; i < 5000; i++)
{
string lastName = reader.ReadCellAsText(sheetTitle, string.Format("C{0}", i + 13));
string firstName = reader.ReadCellAsText(sheetTitle, string.Format("D{0}", i + 13));
if (lastName.IsNullOrEmpty() && firstName.IsNullOrEmpty()) break; // finish after reading last row
PAS pas = new PAS();
pas.Identifier = (i + 1).ToString();
pas.MessageHeader = pasMessage;
newPasList.Add(pas);
pas.PassengerLastName = lastName;
pas.PassengerFirstName = firstName;
pas.PassengerNationality = ReadNationality(reader.ReadCellAsText(sheetTitle, string.Format("F{0}", i + 13)), out bool canceled);
if (canceled) return true;
pas.PassengerGender = ReadGender(reader.ReadCellAsText(sheetTitle, string.Format("E{0}", i + 13)), out canceled);
if (canceled) return true;
pas.PassengerPortOfEmbarkation = ReadLocode(reader.ReadCellAsText(sheetTitle, string.Format("G{0}", i + 13)), out canceled);
if (canceled) return true;
pas.PassengerPortOfDisembarkation = ReadLocode(reader.ReadCellAsText(sheetTitle, string.Format("H{0}", i + 13)), out canceled);
if (canceled) return true;
pas.PassengerInTransit = reader.ReadCellAsBool(sheetTitle, string.Format("I{0}", i + 13));
pas.PassengerPlaceOfBirth = reader.ReadCellAsText(sheetTitle, string.Format("J{0}", i + 13));
DateTime? dateOfBirth = reader.ReadCellAsDateTime(sheetTitle, string.Format("K{0}", i + 13));
pas.PassengerDateOfBirth = dateOfBirth;
pas.PassengerIdentityDocumentType = ReadDocumentType(reader.ReadCellAsText(sheetTitle, string.Format("L{0}", i + 13)), out canceled);
if (canceled) return true;
pas.PassengerIdentityDocumentId = reader.ReadCellAsText(sheetTitle, string.Format("M{0}", i + 13));
pas.PassengerIdentityDocumentExpiryDate = new DateTime(2100, 12, 31);
pas.PassengerIdentityDocumentIssuingState = "XX";
pas.PassengerVisaNumber = reader.ReadCellAsText(sheetTitle, string.Format("N{0}", i + 13));
Util.UIHelper.SetBusyState(); // dialog might reset busy state
}
}
else
{
return false;
}
}
DBManager.Instance.DeleteAllPASForMessage(pasMessage.Id); DBManager.Instance.DeleteAllPASForMessage(pasMessage.Id);
pasMessage.Elements.Clear(); pasMessage.Elements.Clear();
@ -2255,7 +2407,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion PAS
#region PASD #region PASD
@ -2326,7 +2478,7 @@ namespace ENI2.Excel
return true; return true;
} }
#endregion #endregion PASD
#region ScanMessage (generic) #region ScanMessage (generic)
@ -2388,7 +2540,8 @@ namespace ENI2.Excel
{ {
bool? sheetValue = reader.ReadBoolean(lookupNameAttribute.LookupName); bool? sheetValue = reader.ReadBoolean(lookupNameAttribute.LookupName);
string boolStringValue = reader.ReadText(lookupNameAttribute.LookupName); string boolStringValue = reader.ReadText(lookupNameAttribute.LookupName);
if (sheetValue.HasValue) { if (sheetValue.HasValue)
{
property.SetValue(dbEntity, sheetValue); property.SetValue(dbEntity, sheetValue);
} }
} }
@ -2396,12 +2549,10 @@ namespace ENI2.Excel
{ {
_log.DebugFormat("unhandled property type: {0}", property.PropertyType); _log.DebugFormat("unhandled property type: {0}", property.PropertyType);
} }
}
} }
} #endregion ScanMessage (generic)
#endregion
#region LookupMessageCore #region LookupMessageCore
@ -2429,7 +2580,9 @@ namespace ENI2.Excel
return result; return result;
} }
#endregion #endregion LookupMessageCore
#region GetMessageWithType #region GetMessageWithType
@ -2450,7 +2603,7 @@ namespace ENI2.Excel
return newMessage; return newMessage;
} }
#endregion #endregion GetMessageWithType
#region "Semi-Manual" import functions (may open interactive dialog) #region "Semi-Manual" import functions (may open interactive dialog)
@ -2647,6 +2800,6 @@ namespace ENI2.Excel
return result; return result;
} }
#endregion #endregion "Semi-Manual" import functions (may open interactive dialog)
} }
} }

View File

@ -269,5 +269,24 @@ namespace ENI2
return result; return result;
} }
public static List<KeyValuePair<string, string>> GetNST2007List()
{
List<KeyValuePair<string, string>> result = new List<KeyValuePair<string, string>>();
string query = string.Format("SELECT Description, NST2007 FROM LADG_NST2007 ORDER BY Description");
SQLiteCommand cmd = new SQLiteCommand(query, _con);
IDataReader reader = cmd.ExecuteReader();
while (reader.Read())
{
if (reader.IsDBNull(0)) continue;
string desc = reader.GetString(0);
string code = reader.GetString(1);
KeyValuePair<string, string> kvp = new KeyValuePair<string, string>(desc, code);
result.Add(kvp);
}
reader.Close();
return result;
}
} }
} }

View File

@ -207,6 +207,18 @@ namespace ENI2
e.Cancel = true; e.Cancel = true;
} }
// Dez.22: Special case for BRE/BRV: Warning if some messages are not "confirmed"
if(drc.Core.PoC.Equals("DEBRE")||drc.Core.PoC.Equals("DEBRV"))
{
if(drc.HasCriticalInfoMissing(out string missingClass))
{
_log.WarnFormat("set close warning because at least {0} is missing from BRE/BRV arrival", missingClass);
if (MessageBox.Show(string.Format(Properties.Resources.textSpecialCaseBREBRV, missingClass), Properties.Resources.textConfirmation, MessageBoxButton.YesNo,
MessageBoxImage.Question, MessageBoxResult.No) == MessageBoxResult.No)
e.Cancel = true;
}
}
if (!e.Cancel) if (!e.Cancel)
{ {
if (lockedCores.ContainsKey(tabItem)) if (lockedCores.ContainsKey(tabItem))

View File

@ -2040,6 +2040,15 @@ namespace ENI2.Properties {
} }
} }
/// <summary>
/// Looks up a localized string similar to Editor.
/// </summary>
public static string textEditor {
get {
return ResourceManager.GetString("textEditor", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to Edit rules. /// Looks up a localized string similar to Edit rules.
/// </summary> /// </summary>
@ -4236,6 +4245,15 @@ namespace ENI2.Properties {
} }
} }
/// <summary>
/// Looks up a localized string similar to Search NST2007 list.
/// </summary>
public static string textSearchNST {
get {
return ResourceManager.GetString("textSearchNST", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to SEC - Security. /// Looks up a localized string similar to SEC - Security.
/// </summary> /// </summary>
@ -4533,6 +4551,15 @@ namespace ENI2.Properties {
} }
} }
/// <summary>
/// Looks up a localized string similar to At least one of NOA_NOD, AGNT, INFO, SEC, TIEFA hasn&apos;t been sent for DEBRE/DEBRV: ({0}) Close anyway?.
/// </summary>
public static string textSpecialCaseBREBRV {
get {
return ResourceManager.GetString("textSpecialCaseBREBRV", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to Special requirements. /// Looks up a localized string similar to Special requirements.
/// </summary> /// </summary>

View File

@ -1852,4 +1852,13 @@
<data name="textNewDGItem" xml:space="preserve"> <data name="textNewDGItem" xml:space="preserve">
<value>New dangerous goods item</value> <value>New dangerous goods item</value>
</data> </data>
<data name="textEditor" xml:space="preserve">
<value>Editor</value>
</data>
<data name="textSearchNST" xml:space="preserve">
<value>Search NST2007 list</value>
</data>
<data name="textSpecialCaseBREBRV" xml:space="preserve">
<value>At least one of NOA_NOD, AGNT, INFO, SEC, TIEFA hasn't been sent for DEBRE/DEBRV: ({0}) Close anyway?</value>
</data>
</root> </root>

View File

@ -24,7 +24,7 @@ namespace bsmd.database
#region Properties #region Properties
[ShowReport] [ShowReport]
[Validation(ValidationCode.NOT_NULL)] // [Validation(ValidationCode.NOT_NULL)] // damit sieht die Validierung "sauberer" aus (v7.7, Dez. 2022)
[LookupName("ATA.ATAPortOfCall")] [LookupName("ATA.ATAPortOfCall")]
[ENI2Validation] [ENI2Validation]
public DateTime? ATAPortOfCall { get; set; } public DateTime? ATAPortOfCall { get; set; }

View File

@ -24,7 +24,7 @@ namespace bsmd.database
#region Properties #region Properties
[ShowReport] [ShowReport]
[Validation(ValidationCode.NOT_NULL)] // [Validation(ValidationCode.NOT_NULL)] // damit sieht die Validierung "sauberer" aus (v7.7, Dez. 2022)
[LookupName("ATD.ATDPortOfCall")] [LookupName("ATD.ATDPortOfCall")]
[ENI2Validation] [ENI2Validation]
public DateTime? ATDPortOfCall { get; set; } public DateTime? ATDPortOfCall { get; set; }

View File

@ -256,10 +256,9 @@ namespace bsmd.database
public override void Validate(List<MessageError> errors, List<MessageViolation> violations) public override void Validate(List<MessageError> errors, List<MessageViolation> violations)
{ {
if (this.GetValidationBlock() == ValidationBlock.BLOCK1) if (this.GetValidationBlock() == ValidationBlock.BLOCK1) // VISIT
{ {
if(this.ETDFromPortOfCall.HasValue && this.ETAToPortOfCall.HasValue && if(this.ETDFromPortOfCall.HasValue && this.ETAToPortOfCall.HasValue && (this.ETDFromPortOfCall < this.ETAToPortOfCall))
(this.ETDFromPortOfCall < this.ETAToPortOfCall))
errors.Add(RuleEngine.CreateError(ValidationCode.E121, "ETDFromPortOfCall implausible", this.ETDFromPortOfCall?.ToLocalTime().ToString(), this.Title, null, this.Tablename)); errors.Add(RuleEngine.CreateError(ValidationCode.E121, "ETDFromPortOfCall implausible", this.ETDFromPortOfCall?.ToLocalTime().ToString(), this.Title, null, this.Tablename));
// 8.11.20 Validierung gegen ETA /ETD in der Vergangenheit // 8.11.20 Validierung gegen ETA /ETD in der Vergangenheit
@ -267,23 +266,16 @@ namespace bsmd.database
{ {
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETAToPortOfCall: might be implausible", this.ETAToPortOfCall.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename)); violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETAToPortOfCall: might be implausible", this.ETAToPortOfCall.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename));
} }
// NSW 7.1 ETDFromLastPort Pflichtfeld, wenn LastPort != ZZUKN
if(!this.LastPort.IsNullOrEmpty() && !this.LastPort.Equals("ZZUKN") && !this.ETDFromLastPort.HasValue)
{
errors.Add(RuleEngine.CreateError(ValidationCode.E125, "ETDFromLastPort must be provided for a given last port", "", this.Title, null, this.Tablename));
}
if((this.ETDFromLastPort < DateTime.Now.AddDays(-14)) || (this.ETDFromLastPort.HasValue && this.ETDFromLastPort.Value.ToLocalTime().IsTimeEmpty()))
{
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETDFromLastPort: might be implausible", this.ETDFromLastPort.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename));
}
if ((this.ETDFromPortOfCall < DateTime.Now.AddDays(-14)) || (this.ETDFromPortOfCall > DateTime.Now.AddDays(14)) || (this.ETDFromPortOfCall.HasValue && this.ETDFromPortOfCall.Value.ToLocalTime().IsTimeEmpty())) if ((this.ETDFromPortOfCall < DateTime.Now.AddDays(-14)) || (this.ETDFromPortOfCall > DateTime.Now.AddDays(14)) || (this.ETDFromPortOfCall.HasValue && this.ETDFromPortOfCall.Value.ToLocalTime().IsTimeEmpty()))
{ {
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETDFromPortOfCall: might be implausible", this.ETDFromPortOfCall.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename)); violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETDFromPortOfCall: might be implausible", this.ETDFromPortOfCall.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename));
} }
if ((this.ETAToNextPort < DateTime.Now) || (this.ETAToNextPort > DateTime.Now.AddDays(14)) || (this.ETAToNextPort.HasValue && this.ETAToNextPort.Value.ToLocalTime().IsTimeEmpty()))
{ if (this.ETDFromPortOfCall.HasValue && this.ETAToNextPort.HasValue && (this.NextPort?.Equals("ZZUKN") == false) && (this.ETAToNextPort <= ETDFromPortOfCall))
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETAToNextPort: might be implausible", this.ETAToNextPort.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename)); errors.Add(RuleEngine.CreateError(ValidationCode.E122, "ETAToNextPort", null, this.Title, null, this.Tablename));
}
if (this.ETDFromLastPort.HasValue && this.ETAToPortOfCall.HasValue && (this.ETDFromLastPort >= this.ETAToPortOfCall))
errors.Add(RuleEngine.CreateError(ValidationCode.IMPLAUSIBLE, "ETDFromLastPort", null, this.Title, null, this.Tablename));
if (this.CallPurposes.IsNullOrEmpty()) if (this.CallPurposes.IsNullOrEmpty())
{ {
@ -300,34 +292,47 @@ namespace bsmd.database
} }
} }
} }
else else // TRANSIT
{ {
if (this.ETDFromKielCanal.HasValue && this.ETAToKielCanal.HasValue && (this.ETDFromKielCanal < this.ETAToKielCanal)) if (this.ETDFromKielCanal.HasValue && this.ETAToKielCanal.HasValue && (this.ETDFromKielCanal < this.ETAToKielCanal))
errors.Add(RuleEngine.CreateError(ValidationCode.E121, "ETDFromKielCanal implausible", this.ETDFromKielCanal.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename)); errors.Add(RuleEngine.CreateError(ValidationCode.E121, "ETDFromKielCanal implausible", this.ETDFromKielCanal.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename));
if(this.ETDFromKielCanal.HasValue && this.ETDFromKielCanal.Value.ToLocalTime().IsTimeEmpty()) if ((this.ETAToKielCanal < DateTime.Now) || (this.ETAToKielCanal.HasValue && this.ETAToKielCanal.Value.ToLocalTime().IsTimeEmpty()))
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETAToKielCanal: might be implausible", this.ETAToKielCanal.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename));
if ((this.ETDFromKielCanal < DateTime.Now.AddDays(-14)) || (this.ETDFromKielCanal > DateTime.Now.AddDays(14)) || (this.ETDFromKielCanal.HasValue && this.ETDFromKielCanal.Value.ToLocalTime().IsTimeEmpty()))
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETDFromKielCanal: might be implausible", this.ETDFromKielCanal.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename)); violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETDFromKielCanal: might be implausible", this.ETDFromKielCanal.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename));
if(this.ETAToKielCanal.HasValue && this.ETAToKielCanal.Value.ToLocalTime().IsTimeEmpty()) if (this.ETDFromKielCanal.HasValue && this.ETAToNextPort.HasValue && (this.NextPort?.Equals("ZZUKN") == false) && (this.ETAToNextPort <= ETDFromKielCanal))
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETAToKielCanal: might be implausible", this.ETAToKielCanal.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename)); errors.Add(RuleEngine.CreateError(ValidationCode.E122, "ETAToNextPort", null, this.Title, null, this.Tablename));
if (this.ETDFromLastPort.HasValue && this.ETAToKielCanal.HasValue && (this.ETDFromLastPort >= this.ETAToKielCanal))
errors.Add(RuleEngine.CreateError(ValidationCode.IMPLAUSIBLE, "ETDFromLastPort", null, this.Title, null, this.Tablename));
}
// NSW 7.1 ETDFromLastPort Pflichtfeld, wenn LastPort != ZZUKN
if (!this.LastPort.IsNullOrEmpty() && !this.LastPort.Equals("ZZUKN") && !this.ETDFromLastPort.HasValue)
{
errors.Add(RuleEngine.CreateError(ValidationCode.E125, "ETDFromLastPort must be provided for a given last port", "", this.Title, null, this.Tablename));
}
if ((this.ETDFromLastPort < DateTime.Now.AddDays(-14)) || (this.ETDFromLastPort.HasValue && this.ETDFromLastPort.Value.ToLocalTime().IsTimeEmpty()))
{
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETDFromLastPort: might be implausible", this.ETDFromLastPort.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename));
}
if ((this.ETAToNextPort < DateTime.Now) || (this.ETAToNextPort > DateTime.Now.AddDays(14)) || (this.ETAToNextPort.HasValue && this.ETAToNextPort.Value.ToLocalTime().IsTimeEmpty()))
{
violations.Add(RuleEngine.CreateViolation(ValidationCode.TIME_IMPLAUSIBLE, "Check ETAToNextPort: might be implausible", this.ETAToNextPort.Value.ToLocalTime().ToString(), this.Title, null, this.Tablename));
} }
if ((this.LastPort?.Equals("ZZUKN") == true) && this.ETDFromLastPort.HasValue) if ((this.LastPort?.Equals("ZZUKN") == true) && this.ETDFromLastPort.HasValue)
errors.Add(RuleEngine.CreateError(ValidationCode.IMPLAUSIBLE_ZZUKN, "ETDFromLastPort cannot be set if ZZUKN", null, this.Title, null, this.Tablename)); errors.Add(RuleEngine.CreateError(ValidationCode.IMPLAUSIBLE_ZZUKN, "ETDFromLastPort cannot be set if ZZUKN", null, this.Title, null, this.Tablename));
if (this.ETDFromPortOfCall.HasValue && this.ETAToNextPort.HasValue && (this.NextPort?.Equals("ZZUKN") == false) &&
(this.ETAToNextPort <= ETDFromPortOfCall))
errors.Add(RuleEngine.CreateError(ValidationCode.E122, "ETAToNextPort", null, this.Title, null, this.Tablename));
if ((this.NextPort?.Equals("ZZUKN") == false) && !this.ETAToNextPort.HasValue) if ((this.NextPort?.Equals("ZZUKN") == false) && !this.ETAToNextPort.HasValue)
errors.Add(RuleEngine.CreateError(ValidationCode.NOT_NULL, "ETAToNextPort missing", null, this.Title, null, this.Tablename)); errors.Add(RuleEngine.CreateError(ValidationCode.NOT_NULL, "ETAToNextPort missing", null, this.Title, null, this.Tablename));
if((this.NextPort?.Equals("ZZUKN") == true) && this.ETAToNextPort.HasValue) if((this.NextPort?.Equals("ZZUKN") == true) && this.ETAToNextPort.HasValue)
errors.Add(RuleEngine.CreateError(ValidationCode.IMPLAUSIBLE_ZZUKN, "ETAToNextPort cannot be set if ZZUKN", null, this.Title, null, this.Tablename)); errors.Add(RuleEngine.CreateError(ValidationCode.IMPLAUSIBLE_ZZUKN, "ETAToNextPort cannot be set if ZZUKN", null, this.Title, null, this.Tablename));
if (this.ETDFromLastPort.HasValue && this.ETAToPortOfCall.HasValue && (this.ETDFromLastPort >= this.ETAToPortOfCall))
errors.Add(RuleEngine.CreateError(ValidationCode.IMPLAUSIBLE, "ETDFromLastPort", null, this.Title, null, this.Tablename));
} }
public override DatabaseEntity.ValidationBlock GetValidationBlock() public override DatabaseEntity.ValidationBlock GetValidationBlock()

View File

@ -2,6 +2,6 @@
[assembly: AssemblyCompany("schick Informatik")] [assembly: AssemblyCompany("schick Informatik")]
[assembly: AssemblyProduct("BSMD NSW interface")] [assembly: AssemblyProduct("BSMD NSW interface")]
[assembly: AssemblyInformationalVersion("7.6.0")] [assembly: AssemblyInformationalVersion("7.7.0")]
[assembly: AssemblyCopyright("Copyright © 2014-2022 schick Informatik")] [assembly: AssemblyCopyright("Copyright © 2014-2022 schick Informatik")]
[assembly: AssemblyTrademark("")] [assembly: AssemblyTrademark("")]

View File

@ -1,4 +1,4 @@
using System.Reflection; using System.Reflection;
[assembly: AssemblyVersion("7.6.0.*")] [assembly: AssemblyVersion("7.7.0.*")]

View File

@ -42,7 +42,11 @@ namespace bsmd.database
/// <summary> /// <summary>
/// System-User (Testing, Tool) /// System-User (Testing, Tool)
/// </summary> /// </summary>
SYSTEM = 4 SYSTEM = 4,
/// <summary>
/// kann bestimmte Dinge (e.g. templates) im ENI bearbeiten
/// </summary>
EDITOR = 8
}; };
#endregion #endregion
@ -156,6 +160,12 @@ namespace bsmd.database
set { this.SetUserFlag(value, UserFlags.ADMIN); } set { this.SetUserFlag(value, UserFlags.ADMIN); }
} }
public bool IsEditor
{
get { return (this.Flags & (int)UserFlags.EDITOR) != 0; }
set { this.SetUserFlag(value, UserFlags.EDITOR); }
}
#endregion #endregion
#endregion #endregion

3011
misc/LADG_NST2007.csv Normal file

File diff suppressed because it is too large Load Diff

17
misc/bsmd-emswe_eu.csr Normal file
View File

@ -0,0 +1,17 @@
-----BEGIN CERTIFICATE REQUEST-----
MIICsDCCAZgCAQAwazELMAkGA1UEBhMCREUxDzANBgNVBAgMBkJyZW1lbjEPMA0G
A1UEBwwGQnJlbWVuMSIwIAYDVQQKDBlCcmVtZXIgU2NoaWZmc21lbGRlZGllbnN0
MRYwFAYDVQQDDA1ic21kLWVtc3dlLmV1MIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8A
MIIBCgKCAQEApvboTA8dRaz1hBcv3y6v+CBIdE3jUPNqOsZAjGuD9+gpCFv9F/ve
r+kQGvfRCPTPTPk7FM4hC2TKGk6PwmshkWdru4c4S7mYJW3KGe7t0wIgv/g1FkUV
eR5sXl4zvHnBXuV+ciuqb8RVW7izuNHVVUFAVhUlGROBb2ERqW5Cq7JCUM68H6l6
ZAW0yltrO0BSEV6UTxja3f9K4Sz1AcvXXxFeJGUoUZ9J83n3kS5vGyyjeqA3mz7j
NrkYxvXgRJHw4qBxnNtj0YkmwNPg/KFtNslsbUjvdA83s1dYIJA2YaoJPu+b/Nj0
guUaNbxUcFXP7VxU9P1sj5/Nwu4yef2a9wIDAQABoAAwDQYJKoZIhvcNAQELBQAD
ggEBADXDUI9c6GI1hv4AB//E0RBD0aJzuM8hLCI5GDEkgwfhdTI/QOHTZI6G+TT5
mq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NlcnQuY29tL0VuY3J5cHRpb25FdmVyeXdoZXJlRFZUTFNDQS1H
MS5jcnQwCQYDVR0TBAIwADCCAX8GCisGAQQB1nkCBAIEggFvBIIBawFpAHcA6D7Q
2j71BjUy51covIlryQPTy9ERa+zraeF3fW0GvW4AAAGER8N2hQAABAMASDBGAiEA
jFJjUH0ypQ2CZysGcxDsuQGWiXKC2YLwcdDi/TRVUmQCIQCQ8Z8eTutA7+z5GQeZ
sTDcWliMWwg0opagw6jGYeEJrwB1ALNzdwfhhFD4Y4bWBancEQlKeS2xZwwLh9zw
Aw55NqWaAAABhEfDdqkAAAQDAEYwRAIgfq4ILA3L781Wpl9MzwuZ4QwYfs9PXAcf
mwwVWIdp6M8CIF8mK3ze6v6Qomtw7Yyah1VdHKW2G6X0EVbMlb6iG1o1AHcAtz77
JN+cTbp18jnFulj0bF38Qs96nzXEnh0JgSXttJkAAAGER8N2YAAABAMASDBGAiEA
lIYSvWBcBkpB++CkL+9DzhNl51hUgDYGupKgipq7gkkCIQDfwVzxkg9mJlpVpaGA
rQmVs8gtAJTa5Ko72522DGbjxzANBgkqhkiG9w0BAQsFAAOCAQEALOEtbhcB4kB9
1rkD0hoTzmy2lOZ/EuBXnrKzqTxtgDcCX7WUY6shIZYKqD1mjsUNwsd4LuAsZ18X
1+dR2ynhfe0P2HFjrHFF29E5Vn8MWDuzmfW8OglJdz2uckh2VW0Q/ydjpEvBGyZe
Tzms0HnyLPJrCRM7T3hSlTff2DF5SZCOsDg53rex6bcg5jS9tZjcs17wZzm5Hw6J
+39eSN7nwnl5DxJ5sFd0lRaQ7UnDSB1/HWKQA9NEHuuE93sMb/yfWfxAcnFJQ8pn
mj1rVqoyAgB/jQT5Q/fXIfDM0IwaZcWWc4lu70nzbpqgXzPXrC0IdkuRtfMoDI88
6u/DhTWwmA==
-----END CERTIFICATE-----

Binary file not shown.

View File

@ -2,11 +2,8 @@
2) Prüfen ob das ENI App logo richtig ist 2) Prüfen ob das ENI App logo richtig ist
3) VS: Publish: Folder Location und Url richtig auswählen 3) VS: Publish: Folder Location und Url richtig auswählen
4) Signing: "Sign the ClickOnce manifests": Hier für Prod das Zertifikat 4) Signing: "Sign the ClickOnce manifests": Hier für Prod das Zertifikat
auswählen, das am 10.5.23 abläuft. Das Test Zertifikat läuft am 12.11.22 ab. Schiffsmelder CA auswählen, das am 02/24 abläuft.
Auswahl über "Select from Store.." Auswahl über "Select from Store.."
5) Release build einstellen 5) Release Build einstellen
6) komplett neu bauen (clean!) 6) komplett neu bauen (clean!)
7) In Publish -> Options -> Description bei Product name "ENI" statt "ENI Testversion" 7) In Description bei Product name "ENI" statt "ENI Testversion"
8) Publish now
9) Upload
10) last/next Version.txt pflegen

View File

@ -0,0 +1,27 @@
-----BEGIN CERTIFICATE-----
MIIEqjCCA5KgAwIBAgIQAnmsRYvBskWr+YBTzSybsTANBgkqhkiG9w0BAQsFADBh
MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
QTAeFw0xNzExMjcxMjQ2MTBaFw0yNzExMjcxMjQ2MTBaMG4xCzAJBgNVBAYTAlVT
MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
b20xLTArBgNVBAMTJEVuY3J5cHRpb24gRXZlcnl3aGVyZSBEViBUTFMgQ0EgLSBH
MTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBALPeP6wkab41dyQh6mKc
oHqt3jRIxW5MDvf9QyiOR7VfFwK656es0UFiIb74N9pRntzF1UgYzDGu3ppZVMdo
lbxhm6dWS9OK/lFehKNT0OYI9aqk6F+U7cA6jxSC+iDBPXwdF4rs3KRyp3aQn6pj
pp1yr7IB6Y4zv72Ee/PlZ/6rK6InC6WpK0nPVOYR7n9iDuPe1E4IxUMBH/T33+3h
yu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