Merge branch 'release/eni_7.2.4'

This commit is contained in:
Daniel Schick 2024-10-21 12:15:24 +02:00
commit d3af86cefd
65 changed files with 1151 additions and 330 deletions

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<!--
(c) 2017-present Informatikbüro Daniel Schick
-->
@ -50,4 +50,24 @@
<endpoint address="http://localhost:11651/LockingService.svc" binding="basicHttpBinding" bindingConfiguration="BasicHttpBinding_IService" contract="LockingServiceReference.IService" name="BasicHttpBinding_IService" />
</client>
</system.serviceModel>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="Microsoft.Extensions.DependencyInjection.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-8.0.0.2" newVersion="8.0.0.2" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.Extensions.Logging.Abstractions" publicKeyToken="adb9793829ddae60" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-8.0.0.2" newVersion="8.0.0.2" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Memory" publicKeyToken="cc7b13ffcd2ddd51" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-4.0.1.2" newVersion="4.0.1.2" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Runtime.CompilerServices.Unsafe" publicKeyToken="b03f5f7f11d50a3a" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-6.0.0.0" newVersion="6.0.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>

View File

@ -6,6 +6,8 @@ using System.Windows;
using System.Windows.Markup;
using bsmd.database;
using log4net;
using System.Windows.Controls;
using System.Windows.Input;
using System;
@ -13,13 +15,16 @@ using System.Net;
using ENI2.LockingServiceReference;
using ENI2.Util;
using System.Threading;
using System.Threading.Tasks;
using Microsoft.Office.Interop.Excel;
using System.Drawing.Drawing2D;
namespace ENI2
{
/// <summary>
/// Interaction logic for App.xaml
/// </summary>
public partial class App : Application
public partial class App : System.Windows.Application
{
// "global" statics, da gibt es sicher noch einen eleganteren Weg..
private static ServiceClient _lockingServiceClient = null;
@ -30,6 +35,8 @@ namespace ENI2
private ManualResetEvent ResetSplashCreated;
private Thread _splashThread;
private ILog _log = LogManager.GetLogger(typeof(App).Name);
public App() : base()
{
this.Dispatcher.UnhandledException += Dispatcher_UnhandledException;
@ -68,12 +75,10 @@ namespace ENI2
// initialize static / localized lookups from sqlite database
string langKey = CultureInfo.CurrentCulture.TwoLetterISOLanguageName;
Dictionary<int, string> cargoHandlingDict = LocalizedLookup.getLADGCargoHandlingStrings(langKey);
foreach (int key in cargoHandlingDict.Keys)
LADG.CargoHandlingDict.Add(key, cargoHandlingDict[key]);
LADG.MVSHLocodes.AddRange(LocalizedLookup.getMVSHLocodes());
EventManager.RegisterClassHandler(typeof(DatePicker), DatePicker.PreviewKeyDownEvent, new KeyEventHandler(this.DatePicker_PreviewKeyDown));
CREW.NationalityDict = LocalizedLookup.getNationalities();
STAT.VesselTypeDict = LocalizedLookup.getVesselTypes();
@ -84,7 +89,7 @@ namespace ENI2
LADG.CargoCodesNST3 = LocalizedLookup.getCargoCodesNST3();
// Load import value mappings
ValueMapping.LoadDicts();
Task.Run(async () => await ValueMapping.LoadDicts());
// Preload validation fields
List<ValidationField> vFields = bsmd.database.ValidationRule.ValidationFields;
@ -154,9 +159,9 @@ namespace ENI2
private void Dispatcher_UnhandledException(object sender, System.Windows.Threading.DispatcherUnhandledExceptionEventArgs e)
{
string errorMessage = string.Format("An unhandled exception occurred: {0}\r\n{1}", e.Exception.Message, e.Exception.StackTrace);
MessageBox.Show(errorMessage, "Error", MessageBoxButton.OK, MessageBoxImage.Error);
// TODO: Dieser Fehler muss irgendwohin gesendet / gespeichert werden
Xceed.Wpf.Toolkit.MessageBox.Show(errorMessage, "Error", MessageBoxButton.OK, MessageBoxImage.Error);
e.Handled = true;
_log.Error(errorMessage);
}
private void DatePicker_PreviewKeyDown(object sender, KeyEventArgs e)

View File

@ -56,6 +56,33 @@
</Grid>
</ControlTemplate>
<!-- Validation Error Template for a DataGrid Row -->
<Style TargetType="{x:Type DataGridRow}">
<Setter Property="ValidationErrorTemplate">
<Setter.Value>
<ControlTemplate>
<Grid Margin="0,-2,0,-2"
ToolTip="{Binding RelativeSource={RelativeSource
FindAncestor, AncestorType={x:Type DataGridRow}},
Path=(Validation.Errors)[0].ErrorContent}">
<Ellipse StrokeThickness="0" Fill="Red"
Width="{TemplateBinding FontSize}"
Height="{TemplateBinding FontSize}" />
<TextBlock Text="!" FontSize="{TemplateBinding FontSize}"
FontWeight="Bold" Foreground="White"
HorizontalAlignment="Center" />
</Grid>
</ControlTemplate>
</Setter.Value>
</Setter>
</Style>
<Style TargetType="{x:Type ToolTip}" >
<Setter Property="OverridesDefaultStyle" Value="true" />

View File

@ -56,6 +56,7 @@ namespace ENI2.Controls
// das hier bildet 1:1 das Kontext-Menü des ANSW ab
public event Action<DatabaseEntity> EditRequested;
public event Action<List<DatabaseEntity>> MultiEditRequested;
public event Action<DatabaseEntity> DeleteRequested;
public event Action CreateRequested;
public event Action RefreshGrid;
@ -206,6 +207,14 @@ namespace ENI2.Controls
if (this.SelectedItems[0] is DatabaseEntity selectedEntity)
this.EditRequested?.Invoke(selectedEntity);
}
if((this.SelectedItems != null) && (this.SelectedItems.Count > 1) && !this.IsReadOnly)
{
List<DatabaseEntity> databaseEntities = new List<DatabaseEntity>();
foreach(DatabaseEntity databaseEntity in this.SelectedItems)
databaseEntities.Add(databaseEntity);
this.MultiEditRequested?.Invoke(databaseEntities);
}
}
protected void printItem(object sender, RoutedEventArgs e)

View File

@ -63,12 +63,19 @@ namespace ENI2.Controls
get { var addButton = (Button)Template.FindName("buttonAdd", this); return addButton.Visibility == Visibility.Visible; }
set
{
var addButton = (Button)Template.FindName("buttonAdd", this); addButton.Visibility = value ? Visibility.Visible : Visibility.Hidden;
var addButton = (Button)Template.FindName("buttonAdd", this);
if (addButton != null)
{
addButton.Visibility = value ? Visibility.Visible : Visibility.Hidden;
}
var okButton = (Button)Template.FindName("buttonOK", this);
if (okButton != null)
{
if (okButton.Visibility == Visibility.Hidden)
okButton.Width = 1; // we are in a DockPanel, try to collapse okButton to place addButton more to the right
}
}
}
public bool OkVisible
{

View File

@ -79,6 +79,11 @@ namespace ENI2.Controls
portName = LocodeDB.PortNameFromLocode(value); break;
case RuleEngine.LocodeMode.SSN:
portName = LocodeDB.SSNPortNameFromLocode(value); break;
case RuleEngine.LocodeMode.OLD:
portName = LocodeDB.PortNameFromLocode(value);
if ((portName == null) && value.Equals("DEWHV"))
portName = "Stadthafen Wilhelmshaven";
break;
}
LocodeState locodeState = portName.IsNullOrEmpty() ? LocodeState.INVALID : LocodeState.OK;
this.SetLocodeStateImage(this.imageLocodeState, locodeState);
@ -164,6 +169,18 @@ namespace ENI2.Controls
portname = LocodeDB.PortNameFromLocode(directLocode); break;
case RuleEngine.LocodeMode.SSN:
portname = LocodeDB.SSNPortNameFromLocode(directLocode); break;
case RuleEngine.LocodeMode.OLD:
{
if (directLocode.Equals("DEWHV"))
{
portname = "Stadthafen Wilhelmshaven";
}
else
{
portname = LocodeDB.PortNameFromLocode(directLocode);
}
}
break;
}
bool isLocode = !portname.IsNullOrEmpty();
@ -191,6 +208,8 @@ namespace ENI2.Controls
locodeEntries = LocodeDB.AllLocodesForCityNameAsEntries(lookupString); break;
case RuleEngine.LocodeMode.SSN:
locodeEntries = LocalizedLookup.SSNAllLocodesForCityNameAsEntries(lookupString); break;
case RuleEngine.LocodeMode.OLD:
locodeEntries = LocodeDB.AllLocodesForCityNameAsEntries(lookupString); break;
}
locodeEntries.Sort();

View File

@ -33,6 +33,7 @@ namespace ENI2
private DependencyPropertyDescriptor _dpComboboxValue;
private DependencyPropertyDescriptor _dpNumericUpdown;
private DependencyPropertyDescriptor _dpIntUpdown;
private readonly Dictionary<Object, Message.NotificationClass> _controlClassDict = new Dictionary<object, Message.NotificationClass>();
private readonly Dictionary<Message.NotificationClass, Message> _typeMessageDict = new Dictionary<Message.NotificationClass, Message>();
@ -89,7 +90,7 @@ namespace ENI2
/// <summary>
/// Eine in der Detailansicht enthaltene Meldeklasse hat sich geändert
/// </summary>
public event Action<Message.NotificationClass> NotificationClassChanged;
public event Action<Message.NotificationClass?> NotificationClassChanged;
/// <summary>
/// Eine Maske soll neu erzeugt werden weil sich dort "indirekt" etwas geändert hat durch eine Änderung in einer anderen Maske.
@ -134,7 +135,6 @@ namespace ENI2
_dpNumericUpdown = DependencyPropertyDescriptor.FromProperty(Xceed.Wpf.Toolkit.DoubleUpDown.ValueProperty, typeof(Xceed.Wpf.Toolkit.DoubleUpDown));
_dpIntUpdown = DependencyPropertyDescriptor.FromProperty(Xceed.Wpf.Toolkit.IntegerUpDown.ValueProperty, typeof(Xceed.Wpf.Toolkit.IntegerUpDown));
foreach(Message message in this.Messages)
{
_typeMessageDict[message.MessageNotificationClass] = message;
@ -258,11 +258,16 @@ namespace ENI2
{
_typeMessageDict[notificationClass].IsDirty = true;
// signal this notification class changed..
this.OnNotificationClassChanged(notificationClass);
}
}
}
}
protected void OnNotificationClassChanged(Message.NotificationClass? notificationClass)
{
this.NotificationClassChanged?.Invoke(notificationClass);
}
}
}
}
#region "BHV Spezial" Datetime Parsing..

View File

@ -551,7 +551,7 @@ namespace ENI2
this.DetailControl_RequestReload(this.Core.Id.Value);
}
private void DetailControl_NotificationClassChanged(Message.NotificationClass notificationClass)
private void DetailControl_NotificationClassChanged(Message.NotificationClass? notificationClass)
{
// in der Übersicht die Meldeklasse als geändert markieren..?
this.buttonSaveAll.Visibility = Visibility.Visible;

View File

@ -71,8 +71,24 @@
AutoGenerateColumns="False" Margin="0,5,0,0">
<DataGrid.Columns>
<DataGridTextColumn Header="" Binding="{Binding Identifier}" IsReadOnly="True" />
<DataGridTextColumn Header="{x:Static p:Resources.textBunkerType}" Binding="{Binding BunkerFuelType}" IsReadOnly="True" Width="0.2*" />
<DataGridTextColumn Header="{x:Static p:Resources.textBunkerQuantity}" Binding="{Binding BunkerFuelQuantity_TNE, Mode=TwoWay}" IsReadOnly="True" Width="0.8*" />
<DataGridTextColumn Header="{x:Static p:Resources.textBunkerType}" Width="0.2*">
<DataGridTextColumn.Binding>
<Binding Path="BunkerFuelType" Mode="TwoWay">
<Binding.ValidationRules>
<util:StringValidationRule MaxLength="100" />
</Binding.ValidationRules>
</Binding>
</DataGridTextColumn.Binding>
</DataGridTextColumn>
<DataGridTextColumn Header="{x:Static p:Resources.textBunkerQuantity}" IsReadOnly="False" Width="0.8*">
<DataGridTextColumn.Binding>
<Binding Path="BunkerFuelQuantity_TNE" Mode="TwoWay">
<Binding.ValidationRules>
<util:NumberValidationRule MaxValue="10000"/>
</Binding.ValidationRules>
</Binding>
</DataGridTextColumn.Binding>
</DataGridTextColumn>
</DataGrid.Columns>
</enictrl:ENIDataGrid>
</GroupBox>

View File

@ -39,6 +39,7 @@ namespace ENI2.DetailViewControls
this.RegisterIntegerUpDownChange(this.integerUpDownPassengersOnBoard, Message.NotificationClass.POBA);
this.RegisterIntegerUpDownChange(this.integerUpDownPersonsOnBoard, Message.NotificationClass.POBA);
this.RegisterIntegerUpDownChange(this.integerUpDownStowawaysOnBoard, Message.NotificationClass.POBA);
this.dataGridBKRA.CellEditEnding += (obj, ev) => { this.SublistElementChanged(Message.NotificationClass.BKRA); };
startupComplete = true;
}
@ -183,6 +184,8 @@ namespace ENI2.DetailViewControls
private void DataGridBKRA_CreateRequested()
{
this.dataGridBKRA.CancelEdit();
this.dataGridBKRA.CancelEdit();
EditBKRDialog ebd = new EditBKRDialog();
ebd.BRKA = new BRKA();
ebd.BRKA.Identifier = BRKA.GetNewIdentifier(this._bkraMessage.Elements);
@ -215,6 +218,8 @@ namespace ENI2.DetailViewControls
{
if (obj is BRKA brka)
{
this.dataGridBKRA.CancelEdit();
this.dataGridBKRA.CancelEdit();
// are you sure dialog is in base class
DBManager.GetSingleCon(Properties.Settings.Default.ConnectionString).Delete(brka);
this._bkraMessage.Elements.Remove(brka);
@ -226,6 +231,10 @@ namespace ENI2.DetailViewControls
private void DataGridBKRA_EditRequested(DatabaseEntity obj)
{
// I am not shitting you: this has to be called TWICE(!) in a row in order to work
// see: https://stackoverflow.com/questions/20204592/wpf-datagrid-refresh-is-not-allowed-during-an-addnew-or-edititem-transaction-m
this.dataGridBKRA.CancelEdit(DataGridEditingUnit.Row);
this.dataGridBKRA.CommitEdit(DataGridEditingUnit.Row, true);
EditBKRDialog eld = new EditBKRDialog();
eld.IsDeparture = false;
@ -236,7 +245,8 @@ namespace ENI2.DetailViewControls
eld.CopyValuesToEntity();
if(!_bkraMessage.Elements.Contains(eld.BRKA))
_bkraMessage.Elements.Add(eld.BRKA);
this.dataGridBKRA.Items.Refresh();
this.dataGridBKRA.ItemsSource = null;
this.dataGridBKRA.ItemsSource = this._bkraMessage.Elements;
eld.BRKA = new BRKA();
eld.BRKA.Identifier = BRKA.GetNewIdentifier(this._bkraMessage.Elements);
eld.BRKA.MessageHeader = _bkraMessage;
@ -247,7 +257,8 @@ namespace ENI2.DetailViewControls
{
if (!_bkraMessage.Elements.Contains(eld.BRKA))
_bkraMessage.Elements.Add(eld.BRKA);
this.dataGridBKRA.Items.Refresh();
this.dataGridBKRA.ItemsSource = null;
this.dataGridBKRA.ItemsSource = this._bkraMessage.Elements;
this.SublistElementChanged(Message.NotificationClass.BKRA);
}
}

View File

@ -65,6 +65,7 @@
<Label Name="labelCrewNotificationSchengen" Content="{x:Static p:Resources.textNotificationSchengen}" />
<CheckBox Name="checkBoxCrewNotificationPAX" IsThreeState="False" VerticalAlignment="Center" Margin="10,0,0,0" Click="checkBoxCrewNotificationPAX_Click"/>
<Label Name="labelCrewNotificationPAX" Content="{x:Static p:Resources.textNotificationPAX}" />
<Button Name="buttonDeleteAllCrewA" Margin="2" Content="{x:Static p:Resources.textDeleteAllEntries}" Background="Transparent" Click="buttonDeleteAllCrewA_Click"/>
<TextBlock Margin="30,0,0,0" FontWeight="Bold" FontSize="16" Text="CREWA" VerticalAlignment="Center" />
</StackPanel>
@ -107,6 +108,7 @@
<Label Name="labelCrewNotificationSchengenDeparture" Content="{x:Static p:Resources.textNotificationSchengen}" />
<CheckBox Name="checkBoxCrewNotificationPAXDeparture" IsThreeState="False" VerticalAlignment="Center" Margin="10,0,0,0" Click="checkBoxCrewNotificationPAXDeparture_Click"/>
<Label Name="labelCrewNotificationPAXDeparture" Content="{x:Static p:Resources.textNotificationPAX}" />
<Button Name="buttonDeleteAllCrewD" Margin="2" Content="{x:Static p:Resources.textDeleteAllEntries}" Background="Transparent" Click="buttonDeleteAllCrewD_Click"/>
<TextBlock Margin="30,0,0,0" FontWeight="Bold" FontSize="16" Text="CREWD" VerticalAlignment="Center" />
</StackPanel>
<enictrl:ENIDataGrid Grid.Row="1" Grid.Column="0" x:Name="dataGridCrewListDeparture" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"
@ -147,6 +149,7 @@
<Label Name="labelPasNotificationSchengen" Content="{x:Static p:Resources.textNotificationSchengen}" />
<CheckBox Name="checkBoxPasNotificationPAX" IsThreeState="False" VerticalAlignment="Center" Margin="10,0,0,0" Click="checkBoxPasNotificationPAX_Click"/>
<Label Name="labelPasNotificationPAX" Content="{x:Static p:Resources.textNotificationPAX}" />
<Button Name="buttonDeleteAllPasA" Margin="2" Content="{x:Static p:Resources.textDeleteAllEntries}" Background="Transparent" Click="buttonDeleteAllPasA_Click"/>
<TextBlock Margin="30,0,0,0" FontWeight="Bold" FontSize="16" Text="PASA" VerticalAlignment="Center" />
</StackPanel>
<enictrl:ENIDataGrid Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2" x:Name="dataGridPassengerList" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"
@ -192,6 +195,7 @@
<Label Name="labelPasNotificationSchengenDeparture" Content="{x:Static p:Resources.textNotificationSchengen}" />
<CheckBox Name="checkBoxPasNotificationPAXDeparture" IsThreeState="False" VerticalAlignment="Center" Margin="10,0,0,0" Click="checkBoxPasNotificationPAXDeparture_Click"/>
<Label Name="labelPasNotificationPAXDeparture" Content="{x:Static p:Resources.textNotificationPAX}" />
<Button Name="buttonDeleteAllPasD" Margin="2" Content="{x:Static p:Resources.textDeleteAllEntries}" Background="Transparent" Click="buttonDeleteAllPasD_Click"/>
<TextBlock Margin="30,0,0,0" FontWeight="Bold" FontSize="16" Text="PASD" VerticalAlignment="Center" />
</StackPanel>
<enictrl:ENIDataGrid Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2" x:Name="dataGridPassengerListDeparture" HorizontalContentAlignment="Stretch" VerticalContentAlignment="Stretch"

View File

@ -14,6 +14,7 @@ using ENI2.Locode;
using ExcelDataReader;
using bsmd.database;
using System.Windows.Media.Imaging;
using System.Linq;
namespace ENI2.DetailViewControls
{
@ -113,6 +114,7 @@ namespace ENI2.DetailViewControls
this.dataGridCrewList.DeleteRequested += DataGridCrewList_DeleteRequested;
this.dataGridCrewList.CreateRequested += DataGridCrewList_CreateRequested;
this.dataGridCrewList.RefreshGrid += DataGridCrewList_RefreshGrid;
this.dataGridCrewList.MultiEditRequested += DataGridCrewList_MultiEditRequested;
if(this._crewMessage.Elements.Count > 0)
{
@ -149,6 +151,7 @@ namespace ENI2.DetailViewControls
this.dataGridCrewListDeparture.DeleteRequested += DataGridCrewListDeparture_DeleteRequested;
this.dataGridCrewListDeparture.CreateRequested += DataGridCrewListDeparture_CreateRequested;
this.dataGridCrewListDeparture.RefreshGrid += DataGridCrewListDeparture_RefreshGrid;
this.dataGridCrewListDeparture.MultiEditRequested += DataGridCrewListDeparture_MultiEditRequested;
if (this._crewdMessage.Elements.Count > 0)
{
@ -185,6 +188,7 @@ namespace ENI2.DetailViewControls
this.dataGridPassengerList.DeleteRequested += DataGridPassengerList_DeleteRequested;
this.dataGridPassengerList.CreateRequested += DataGridPassengerList_CreateRequested;
this.dataGridPassengerList.RefreshGrid += DataGridPassengerList_RefreshGrid;
this.dataGridPassengerList.MultiEditRequested += DataGridPassengerList_MultiEditRequested;
if (this._pasMessage.Elements.Count > 0)
{
@ -221,6 +225,7 @@ namespace ENI2.DetailViewControls
this.dataGridPassengerListDeparture.DeleteRequested += DataGridPassengerListDeparture_DeleteRequested;
this.dataGridPassengerListDeparture.CreateRequested += DataGridPassengerListDeparture_CreateRequested;
this.dataGridPassengerListDeparture.RefreshGrid += DataGridPassengerListDeparture_RefreshGrid;
this.dataGridPassengerListDeparture.MultiEditRequested += DataGridPassengerListDeparture_MultiEditRequested;
if (this._pasdMessage.Elements.Count > 0)
{
@ -629,6 +634,28 @@ namespace ENI2.DetailViewControls
this.DataGridPassengerList_CreateRequested();
}
private void DataGridPassengerList_MultiEditRequested(List<DatabaseEntity> databaseEntities)
{
List<PAS> pasList = new List<PAS>();
foreach (PAS apas in databaseEntities.Cast<PAS>())
pasList.Add(apas);
// write common values of all PAS entities to template entity
PAS pas = PAS.CreateCommon(pasList);
EditPASDialog dialog = new EditPASDialog();
dialog.PAS = pas;
dialog.AddVisible = false;
if (dialog.ShowDialog() ?? false)
{
// write back changed values from pas to all entities and mark them as changed
PAS.WriteTemplateToList(pas, pasList);
this.SublistElementChanged(Message.NotificationClass.PASA);
this.dataGridPassengerList.Items.Refresh();
}
}
#endregion
#region passenger grid departure
@ -733,6 +760,28 @@ namespace ENI2.DetailViewControls
this.DataGridPassengerListDeparture_CreateRequested();
}
private void DataGridPassengerListDeparture_MultiEditRequested(List<DatabaseEntity> databaseEntities)
{
List<PAS> pasList = new List<PAS>();
foreach (PAS apas in databaseEntities.Cast<PAS>())
pasList.Add(apas);
// write common values of all PAS entities to template entity
PAS pas = PAS.CreateCommon(pasList);
EditPASDialog dialog = new EditPASDialog();
dialog.PAS = pas;
dialog.AddVisible = false;
if (dialog.ShowDialog() ?? false)
{
// write back changed values from pas to all entities and mark them as changed
PAS.WriteTemplateToList(pas, pasList);
this.SublistElementChanged(Message.NotificationClass.PASD);
this.dataGridPassengerListDeparture.Items.Refresh();
}
}
#endregion
#region crew grid arrival
@ -834,6 +883,28 @@ namespace ENI2.DetailViewControls
this.DataGridCrewList_CreateRequested();
}
private void DataGridCrewList_MultiEditRequested(List<DatabaseEntity> databaseEntities)
{
List<CREW> crewList = new List<CREW>();
foreach (CREW acrew in databaseEntities.Cast<CREW>())
crewList.Add(acrew);
// write common values of all CREW entities to template entity
CREW crew = CREW.CreateCommon(crewList);
EditCREWDialog dialog = new EditCREWDialog();
dialog.CREW = crew;
dialog.AddVisible = false;
if(dialog.ShowDialog() ?? false)
{
// write back changed values from crew to all entities and mark them as changed
CREW.WriteTemplateToList(crew, crewList);
this.SublistElementChanged(Message.NotificationClass.CREWA);
this.dataGridCrewList.Items.Refresh();
}
}
#endregion
#region crew grid departure
@ -938,6 +1009,28 @@ namespace ENI2.DetailViewControls
this.DataGridCrewListDeparture_CreateRequested();
}
private void DataGridCrewListDeparture_MultiEditRequested(List<DatabaseEntity> databaseEntities)
{
List<CREW> crewList = new List<CREW>();
foreach (CREW acrew in databaseEntities.Cast<CREW>())
crewList.Add(acrew);
// write common values of all CREW entities to template entity
CREW crew = CREW.CreateCommon(crewList);
EditCREWDialog dialog = new EditCREWDialog();
dialog.CREW = crew;
dialog.AddVisible = false;
if (dialog.ShowDialog() ?? false)
{
// write back changed values from crew to all entities and mark them as changed
CREW.WriteTemplateToList(crew, crewList);
this.SublistElementChanged(Message.NotificationClass.CREWD);
this.dataGridCrewListDeparture.Items.Refresh();
}
}
#endregion
#region Excel import
@ -1188,8 +1281,6 @@ namespace ENI2.DetailViewControls
}
}
private void buttonImportExcelPassengerDeparture_Click(object sender, RoutedEventArgs e)
{
OpenFileDialog ofd = new OpenFileDialog
@ -1314,7 +1405,7 @@ namespace ENI2.DetailViewControls
private void checkBoxCrewNotificationSchengen_Click(object sender, RoutedEventArgs e)
{
foreach(CREW crew in _crewMessage.Elements)
foreach(CREW crew in _crewMessage.Elements.Cast<CREW>())
{
crew.NotificationSchengen = checkBoxCrewNotificationSchengen.IsChecked;
}
@ -1324,7 +1415,7 @@ namespace ENI2.DetailViewControls
private void checkBoxCrewNotificationPAX_Click(object sender, RoutedEventArgs e)
{
foreach (CREW crew in _crewMessage.Elements)
foreach (CREW crew in _crewMessage.Elements.Cast<CREW>())
{
crew.NotificationPAX = checkBoxCrewNotificationPAX.IsChecked;
}
@ -1333,7 +1424,7 @@ namespace ENI2.DetailViewControls
private void checkBoxCrewNotificationSchengenDeparture_Click(object sender, RoutedEventArgs e)
{
foreach(CREWD crewd in _crewdMessage.Elements)
foreach(CREWD crewd in _crewdMessage.Elements.Cast<CREWD>())
{
crewd.NotificationSchengen = checkBoxCrewNotificationSchengenDeparture.IsChecked;
}
@ -1342,7 +1433,7 @@ namespace ENI2.DetailViewControls
private void checkBoxCrewNotificationPAXDeparture_Click(object sender, RoutedEventArgs e)
{
foreach (CREWD crewd in _crewdMessage.Elements)
foreach (CREWD crewd in _crewdMessage.Elements.Cast<CREWD>())
{
crewd.NotificationPAX = checkBoxCrewNotificationPAXDeparture.IsChecked;
}
@ -1351,7 +1442,7 @@ namespace ENI2.DetailViewControls
private void checkBoxPasNotificationSchengen_Click(object sender, RoutedEventArgs e)
{
foreach(PAS pas in _pasMessage.Elements)
foreach(PAS pas in _pasMessage.Elements.Cast<PAS>())
{
pas.NotificationSchengen = checkBoxPasNotificationSchengen.IsChecked;
}
@ -1360,7 +1451,7 @@ namespace ENI2.DetailViewControls
private void checkBoxPasNotificationPAX_Click(object sender, RoutedEventArgs e)
{
foreach(PAS pas in _pasMessage.Elements)
foreach(PAS pas in _pasMessage.Elements.Cast<PAS>())
{
pas.NotificationPAX = checkBoxPasNotificationPAX.IsChecked;
}
@ -1369,7 +1460,7 @@ namespace ENI2.DetailViewControls
private void checkBoxPasNotificationSchengenDeparture_Click(object sender, RoutedEventArgs e)
{
foreach(PASD pasd in _pasdMessage.Elements)
foreach(PASD pasd in _pasdMessage.Elements.Cast<PASD>())
{
pasd.NotificationSchengen = checkBoxPasNotificationSchengenDeparture.IsChecked;
}
@ -1378,7 +1469,7 @@ namespace ENI2.DetailViewControls
private void checkBoxPasNotificationPAXDeparture_Click(object sender, RoutedEventArgs e)
{
foreach(PASD pasd in _pasdMessage.Elements)
foreach(PASD pasd in _pasdMessage.Elements.Cast<PASD>())
{
pasd.NotificationPAX = checkBoxPasNotificationPAXDeparture.IsChecked;
}
@ -1387,5 +1478,65 @@ namespace ENI2.DetailViewControls
#endregion
#region Buttons to delete all entries from CREWA CREWD PASA PASD
private async void buttonDeleteAllCrewA_Click(object sender, RoutedEventArgs e)
{
if(MessageBox.Show(Properties.Resources.textConfimDeleteAllEntries, Properties.Resources.textConfirmation, MessageBoxButton.YesNo, MessageBoxImage.Question, MessageBoxResult.No) == MessageBoxResult.Yes)
{
foreach(CREW crewa in this._crewMessage.Elements.Cast<CREW>())
{
await DBManagerAsync.DeleteAsync(crewa);
}
this._crewMessage.Elements.Clear();
this.dataGridCrewList.Items.Refresh();
this.SublistElementChanged(Message.NotificationClass.CREWA);
}
}
private async void buttonDeleteAllCrewD_Click(object sender, RoutedEventArgs e)
{
if (MessageBox.Show(Properties.Resources.textConfimDeleteAllEntries, Properties.Resources.textConfirmation, MessageBoxButton.YesNo, MessageBoxImage.Question, MessageBoxResult.No) == MessageBoxResult.Yes)
{
foreach (CREWD crewd in this._crewdMessage.Elements.Cast<CREWD>())
{
await DBManagerAsync.DeleteAsync(crewd);
}
this._crewdMessage.Elements.Clear();
this.dataGridCrewListDeparture.Items.Refresh();
this.SublistElementChanged(Message.NotificationClass.CREWD);
}
}
private async void buttonDeleteAllPasA_Click(object sender, RoutedEventArgs e)
{
if (MessageBox.Show(Properties.Resources.textConfimDeleteAllEntries, Properties.Resources.textConfirmation, MessageBoxButton.YesNo, MessageBoxImage.Question, MessageBoxResult.No) == MessageBoxResult.Yes)
{
foreach (PAS pasa in this._pasMessage.Elements.Cast<PAS>())
{
await DBManagerAsync.DeleteAsync(pasa);
}
this._pasMessage.Elements.Clear();
this.dataGridPassengerList.Items.Refresh();
this.SublistElementChanged(Message.NotificationClass.PASA);
}
}
private async void buttonDeleteAllPasD_Click(object sender, RoutedEventArgs e)
{
if (MessageBox.Show(Properties.Resources.textConfimDeleteAllEntries, Properties.Resources.textConfirmation, MessageBoxButton.YesNo, MessageBoxImage.Question, MessageBoxResult.No) == MessageBoxResult.Yes)
{
foreach (PASD pasd in this._pasdMessage.Elements.Cast<PASD>())
{
await DBManagerAsync.DeleteAsync(pasd);
}
this._pasdMessage.Elements.Clear();
this.dataGridPassengerListDeparture.Items.Refresh();
this.SublistElementChanged(Message.NotificationClass.PASD);
}
}
#endregion
}
}

View File

@ -70,8 +70,24 @@
AutoGenerateColumns="False" Margin="0,5,0,0">
<DataGrid.Columns>
<DataGridTextColumn Header="" Binding="{Binding Identifier}" IsReadOnly="True" />
<DataGridTextColumn Header="{x:Static p:Resources.textBunkerType}" Binding="{Binding BunkerFuelType}" IsReadOnly="True" Width="0.2*" />
<DataGridTextColumn Header="{x:Static p:Resources.textBunkerQuantity}" Binding="{Binding BunkerFuelQuantity_TNE, Mode=TwoWay}" IsReadOnly="True" Width="0.8*" />
<DataGridTextColumn Header="{x:Static p:Resources.textBunkerType}" Width="0.2*">
<DataGridTextColumn.Binding>
<Binding Path="BunkerFuelType" Mode="TwoWay">
<Binding.ValidationRules>
<util:StringValidationRule MaxLength="100" />
</Binding.ValidationRules>
</Binding>
</DataGridTextColumn.Binding>
</DataGridTextColumn>
<DataGridTextColumn Header="{x:Static p:Resources.textBunkerQuantity}" IsReadOnly="False" Width="0.8*">
<DataGridTextColumn.Binding>
<Binding Path="BunkerFuelQuantity_TNE" Mode="TwoWay">
<Binding.ValidationRules>
<util:NumberValidationRule MaxValue="10000" />
</Binding.ValidationRules>
</Binding>
</DataGridTextColumn.Binding>
</DataGridTextColumn>
</DataGrid.Columns>
</enictrl:ENIDataGrid>
</GroupBox>

View File

@ -40,6 +40,7 @@ namespace ENI2.DetailViewControls
this.RegisterIntegerUpDownChange(this.integerUpDownPassengersOnBoard, Message.NotificationClass.POBD);
this.RegisterIntegerUpDownChange(this.integerUpDownPersonsOnBoard, Message.NotificationClass.POBD);
this.RegisterIntegerUpDownChange(this.integerUpDownStowawaysOnBoard, Message.NotificationClass.POBD);
this.dataGridBKRD.CellEditEnding += (obj, ev) => { this.OnNotificationClassChanged(Message.NotificationClass.BKRD); };
startupComplete = true;
}
@ -167,6 +168,8 @@ namespace ENI2.DetailViewControls
private void DataGridBKRD_CreateRequested()
{
this.dataGridBKRD.CancelEdit();
this.dataGridBKRD.CancelEdit();
EditBKRDialog ebd = new EditBKRDialog();
ebd.IsDeparture = true;
ebd.BRKD = new BRKD();
@ -199,6 +202,8 @@ namespace ENI2.DetailViewControls
{
if (obj is BRKD brkd)
{
this.dataGridBKRD.CancelEdit();
this.dataGridBKRD.CancelEdit();
// are you sure dialog is in base class
this._bkrdMessage.Elements.Remove(brkd);
DBManager.GetSingleCon(Properties.Settings.Default.ConnectionString).Delete(brkd);
@ -210,6 +215,8 @@ namespace ENI2.DetailViewControls
private void DataGridBKRD_EditRequested(DatabaseEntity obj)
{
this.dataGridBKRD.CancelEdit(DataGridEditingUnit.Row);
this.dataGridBKRD.CommitEdit(DataGridEditingUnit.Row, true);
EditBKRDialog eld = new EditBKRDialog();
eld.IsDeparture = true;
eld.BRKD = obj as BRKD;
@ -230,7 +237,8 @@ namespace ENI2.DetailViewControls
{
if (!_bkrdMessage.Elements.Contains(eld.BRKD))
_bkrdMessage.Elements.Add(eld.BRKD);
this.dataGridBKRD.Items.Refresh();
this.dataGridBKRD.ItemsSource = null;
this.dataGridBKRD.ItemsSource = this._bkrdMessage.Elements;
this.SublistElementChanged(Message.NotificationClass.BKRD);
}
}

View File

@ -19,6 +19,8 @@ using System.Collections.Generic;
using System.Windows.Media;
using Microsoft.Win32;
using System.Diagnostics;
using System.ComponentModel;
using static bsmd.database.Message;
namespace ENI2.DetailViewControls
{
@ -46,11 +48,11 @@ namespace ENI2.DetailViewControls
{
// die Controls nach Änderungen monitoren
// diese Einträge gehen auf core
this.RegisterTextboxChange(this.textBoxTicketNo, Message.NotificationClass.ATA);
this.RegisterTextboxChange(this.textBoxDisplayId, Message.NotificationClass.ATA);
this.RegisterTextboxChange(this.textBoxIMO, Message.NotificationClass.ATA);
this.RegisterTextboxChange(this.textBoxENI, Message.NotificationClass.ATA);
this.RegisterLocodeChange(this.locodePoC, Message.NotificationClass.ATA);
this.textBoxTicketNo.TextChanged += CoreTextBox_TextChanged;
this.textBoxDisplayId.TextChanged += CoreTextBox_TextChanged;
this.textBoxIMO.TextChanged += CoreTextBox_TextChanged;
this.textBoxENI.TextChanged += CoreTextBox_TextChanged;
this.locodePoC.PropertyChanged += CoreLocode_LocodeChanged;
this.RegisterDateTimePickerChange(this.dateTimePickerATA, Message.NotificationClass.ATA);
this.RegisterDateTimePickerChange(this.dateTimePickerATD, Message.NotificationClass.ATD);
@ -58,6 +60,16 @@ namespace ENI2.DetailViewControls
this.RegisterDateTimePickerChange(this.dateTimePickerETD, Message.NotificationClass.NOA_NOD);
}
private void CoreLocode_LocodeChanged(object sender, PropertyChangedEventArgs e)
{
this.OnNotificationClassChanged(null);
}
private void CoreTextBox_TextChanged(object sender, TextChangedEventArgs e)
{
this.OnNotificationClassChanged(null);
}
#region Initialize
public override void Initialize()

View File

@ -105,8 +105,27 @@
<DataGridTextColumn Header="{x:Static p:Resources.textLACodes}" Binding="{Binding CargoLACode, Mode=TwoWay}" IsReadOnly="True" Width="0.1*" />
<DataGridTextColumn Header="{x:Static p:Resources.textCargoCodeNST}" Binding="{Binding CargoCodeNST, Mode=TwoWay}" IsReadOnly="True" Width="0.1*" />
<DataGridTextColumn Header="{x:Static p:Resources.textCargoCodeNST3}" Binding="{Binding CargoCodeNST_3, Mode=TwoWay}" IsReadOnly="True" Width="0.15*" />
<DataGridTextColumn Header="{x:Static p:Resources.textCargoNumberOfItems}" Binding="{Binding CargoNumberOfItems, Mode=TwoWay}" IsReadOnly="True" Width="0.15*" />
<DataGridTextColumn Header="{x:Static p:Resources.textCargoGrossQuantity}" Binding="{Binding CargoGrossQuantity_TNE, Mode=TwoWay, StringFormat={}{0:N3}}" IsReadOnly="True" Width="0.15*" />
<DataGridTextColumn Header="{x:Static p:Resources.textCargoNumberOfItems}" IsReadOnly="False" Width="0.15*">
<DataGridTextColumn.Binding>
<Binding Path="CargoNumberOfItems" Mode="TwoWay">
<Binding.ValidationRules>
<util:NumberValidationRule MaxValue="9999999" />
</Binding.ValidationRules>
</Binding>
</DataGridTextColumn.Binding>
</DataGridTextColumn>
<DataGridTextColumn Header="{x:Static p:Resources.textCargoGrossQuantity}" IsReadOnly="False" Width="0.15*">
<DataGridTextColumn.Binding>
<Binding Path="CargoGrossQuantity_TNE" Mode="TwoWay" StringFormat="N3">
<Binding.ValidationRules>
<util:NumberValidationRule MaxValue="1000000" MinValue="0" />
</Binding.ValidationRules>
</Binding>
</DataGridTextColumn.Binding>
</DataGridTextColumn>
<DataGridTextColumn Header="{x:Static p:Resources.textCargoPortOfLoading}" Binding="{Binding PortOfLoading, Mode=TwoWay}" IsReadOnly="True" Width="0.15*" />
<DataGridTextColumn Header="{x:Static p:Resources.textCargoPortOfDischarge}" Binding="{Binding PortOfDischarge, Mode=TwoWay}" IsReadOnly="True" Width="0.15*" />
</DataGrid.Columns>

View File

@ -56,7 +56,7 @@ namespace ENI2.DetailViewControls
this.RegisterDoubleUpDownChange(this.doubleUpDownDisplacementSummerDraught, Message.NotificationClass.INFO);
this.RegisterTextboxChange(this.textSpecialRequirements, Message.NotificationClass.INFO);
this.RegisterTextboxChange(this.textConstructionCharacteristics, Message.NotificationClass.INFO);
this.dataGridLADG.CellEditEnding += (obj, ev) => { this.OnNotificationClassChanged(Message.NotificationClass.LADG); };
}
public override void Initialize()
@ -174,6 +174,8 @@ namespace ENI2.DetailViewControls
private void DataGridLADG_CreateRequested()
{
this.dataGridLADG.CancelEdit();
this.dataGridLADG.CancelEdit();
EditLADGDialog eld = new EditLADGDialog();
eld.LADG = new LADG();
eld.LADG.MessageHeader = _ladgMessage;
@ -206,6 +208,8 @@ namespace ENI2.DetailViewControls
{
if (obj is LADG ladg)
{
this.dataGridLADG.CancelEdit();
this.dataGridLADG.CancelEdit();
// are you sure dialog is in base class
this._ladgMessage.Elements.Remove(ladg);
DBManager.GetSingleCon(Properties.Settings.Default.ConnectionString).Delete(ladg);
@ -217,6 +221,9 @@ namespace ENI2.DetailViewControls
private void DataGridLADG_EditRequested(DatabaseEntity obj)
{
this.dataGridLADG.CancelEdit();
this.dataGridLADG.CancelEdit();
LADG ladg = obj as LADG;
EditLADGDialog eld = new EditLADGDialog();

View File

@ -196,7 +196,7 @@
<DataGridTextColumn Header="" Binding="{Binding Identifier}" IsReadOnly="True" />
<DataGridTextColumn Header="{x:Static p:Resources.textCode}" Binding="{Binding WasteTypeDisplayGrid}" IsReadOnly="True" Width="0.2*" />
<DataGridTextColumn Header="{x:Static p:Resources.textDescription}" Binding="{Binding WasteDescription}" IsReadOnly="True" Width="0.3*" />
<DataGridTemplateColumn IsReadOnly="True" Width="0.15*">
<!--DataGridTemplateColumn IsReadOnly="True" Width="0.15*">
<DataGridTemplateColumn.HeaderTemplate>
<DataTemplate>
<TextBlock TextWrapping="Wrap" Text="{x:Static p:Resources.textAmountWasteReceived_MTQ}" FontSize="10"/>
@ -207,7 +207,16 @@
<TextBlock TextAlignment="Center" Text="{Binding AmountWasteReceived_MTQ, StringFormat={}{0:N3}}" />
</DataTemplate>
</DataGridTemplateColumn.CellTemplate>
</DataGridTemplateColumn>
</DataGridTemplateColumn-->
<DataGridTextColumn Header="{x:Static p:Resources.textAmountWasteReceived_MTQ}" IsReadOnly="False" Width="0.15*">
<DataGridTextColumn.Binding>
<Binding Path="AmountWasteReceived_MTQ" Mode="TwoWay" StringFormat="N3" >
<Binding.ValidationRules>
<util:NumberValidationRule MaxValue="10000" MinValue="0" />
</Binding.ValidationRules>
</Binding>
</DataGridTextColumn.Binding>
</DataGridTextColumn>
</DataGrid.Columns>
</enictrl:ENIDataGrid>

View File

@ -32,13 +32,6 @@ namespace ENI2.DetailViewControls
private WasteDisposalServiceProvider_Template _currentTemplate;
private string _undoTemplate;
private static readonly string[] _wasteDeliveryList =
{
"ALL",
"SOME",
"NONE"
};
public WasteDetailControl()
{
InitializeComponent();
@ -54,7 +47,7 @@ namespace ENI2.DetailViewControls
this.RegisterCheckboxChange(this.checkBoxValidExemption, Message.NotificationClass.WAS);
this.RegisterDatePickerChange(this.datePickerDateLastDisposal, Message.NotificationClass.WAS);
this.RegisterTextboxChange(this.textBoxWasteDisposalServiceProviders, Message.NotificationClass.WAS);
this.dataGridWasteReceived.CellEditEnding += (obj, ev) => { this.SublistElementChanged(Message.NotificationClass.WAS_RCPT); };
}
private void CheckBoxValidExemption_Checked(object sender, RoutedEventArgs e)
@ -297,7 +290,8 @@ namespace ENI2.DetailViewControls
{
if (obj is WasteReceived wasteReceived)
{
this.dataGridWasteReceived.CancelEdit();
this.dataGridWasteReceived.CancelEdit();
// are you sure dialog is in base class
_selectedWAS_RCPT.WasteReceived.Remove(wasteReceived);
DBManager.GetSingleCon(Properties.Settings.Default.ConnectionString).Delete(wasteReceived);
@ -310,6 +304,8 @@ namespace ENI2.DetailViewControls
private void DataGridWasteReceived_CreateRequested()
{
if (_selectedWAS_RCPT == null) return;
this.dataGridWasteReceived.CancelEdit();
this.dataGridWasteReceived.CancelEdit();
EditWasteReceivedDialog ewrd = new EditWasteReceivedDialog();
ewrd.WasteReceived = new WasteReceived();
ewrd.WasteReceived.WAS_RCPT = _selectedWAS_RCPT;
@ -343,6 +339,9 @@ namespace ENI2.DetailViewControls
private void DataGridWasteReceived_EditRequested(DatabaseEntity obj)
{
this.dataGridWasteReceived.CancelEdit();
this.dataGridWasteReceived.CancelEdit();
EditWasteReceivedDialog ewrd = new EditWasteReceivedDialog();
ewrd.WasteReceived = obj as WasteReceived;

View File

@ -30,14 +30,14 @@
<MapFileExtensions>true</MapFileExtensions>
<InstallUrl>http://192.168.2.24/eni2.publish/</InstallUrl>
<SupportUrl>http://www.textbausteine.net/</SupportUrl>
<ProductName>ENI</ProductName>
<ProductName>ENI 2</ProductName>
<PublisherName>Informatikbüro Daniel Schick</PublisherName>
<SuiteName>NSW</SuiteName>
<MinimumRequiredVersion>5.4.0.0</MinimumRequiredVersion>
<CreateWebPageOnPublish>true</CreateWebPageOnPublish>
<WebPage>publish.html</WebPage>
<ApplicationRevision>3</ApplicationRevision>
<ApplicationVersion>7.2.3.3</ApplicationVersion>
<ApplicationRevision>6</ApplicationRevision>
<ApplicationVersion>7.2.4.6</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust>
<CreateDesktopShortcut>true</CreateDesktopShortcut>
<PublishWizardCompleted>true</PublishWizardCompleted>
@ -62,7 +62,8 @@
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<WarningLevel>0</WarningLevel>
<Prefer32Bit>false</Prefer32Bit>
</PropertyGroup>
<PropertyGroup>
<StartupObject>ENI2.App</StartupObject>
@ -134,43 +135,99 @@
<CodeAnalysisRuleSet>..\code.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup>
<Reference Include="ExcelDataReader, Version=3.6.0.0, Culture=neutral, PublicKeyToken=93517dbe6a4012fa, processorArchitecture=MSIL">
<HintPath>packages\ExcelDataReader.3.6.0\lib\net45\ExcelDataReader.dll</HintPath>
<Reference Include="ExcelDataReader, Version=3.7.0.0, Culture=neutral, PublicKeyToken=93517dbe6a4012fa, processorArchitecture=MSIL">
<HintPath>packages\ExcelDataReader.3.7.0\lib\net462\ExcelDataReader.dll</HintPath>
</Reference>
<Reference Include="log4net, Version=2.0.15.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>packages\log4net.2.0.15\lib\net45\log4net.dll</HintPath>
<Reference Include="log4net, Version=3.0.1.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>packages\log4net.3.0.1\lib\net462\log4net.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Bcl.AsyncInterfaces, Version=8.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>packages\Microsoft.Bcl.AsyncInterfaces.8.0.0\lib\net462\Microsoft.Bcl.AsyncInterfaces.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.DependencyInjection, Version=8.0.0.1, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
<HintPath>packages\Microsoft.Extensions.DependencyInjection.8.0.1\lib\net462\Microsoft.Extensions.DependencyInjection.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.DependencyInjection.Abstractions, Version=8.0.0.2, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
<HintPath>packages\Microsoft.Extensions.DependencyInjection.Abstractions.8.0.2\lib\net462\Microsoft.Extensions.DependencyInjection.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Logging, Version=8.0.0.1, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
<HintPath>packages\Microsoft.Extensions.Logging.8.0.1\lib\net462\Microsoft.Extensions.Logging.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Logging.Abstractions, Version=8.0.0.2, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
<HintPath>packages\Microsoft.Extensions.Logging.Abstractions.8.0.2\lib\net462\Microsoft.Extensions.Logging.Abstractions.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Options, Version=8.0.0.2, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
<HintPath>packages\Microsoft.Extensions.Options.8.0.2\lib\net462\Microsoft.Extensions.Options.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Extensions.Primitives, Version=8.0.0.0, Culture=neutral, PublicKeyToken=adb9793829ddae60, processorArchitecture=MSIL">
<HintPath>packages\Microsoft.Extensions.Primitives.8.0.0\lib\net462\Microsoft.Extensions.Primitives.dll</HintPath>
</Reference>
<Reference Include="Microsoft.Office.Interop.Excel, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c, processorArchitecture=MSIL">
<HintPath>packages\Microsoft.Office.Interop.Excel.15.0.4795.1001\lib\net20\Microsoft.Office.Interop.Excel.dll</HintPath>
<EmbedInteropTypes>True</EmbedInteropTypes>
</Reference>
<Reference Include="MigraDoc.DocumentObjectModel-gdi, Version=1.50.5147.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-gdi.1.50.5147\lib\net20\MigraDoc.DocumentObjectModel-gdi.dll</HintPath>
<Reference Include="MigraDoc.DocumentObjectModel, Version=6.1.1.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\MigraDoc.DocumentObjectModel.dll</HintPath>
</Reference>
<Reference Include="MigraDoc.Rendering-gdi, Version=1.50.5147.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-gdi.1.50.5147\lib\net20\MigraDoc.Rendering-gdi.dll</HintPath>
<Reference Include="MigraDoc.Rendering-gdi, Version=6.1.1.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\MigraDoc.Rendering-gdi.dll</HintPath>
</Reference>
<Reference Include="MigraDoc.RtfRendering-gdi, Version=1.50.5147.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-gdi.1.50.5147\lib\net20\MigraDoc.RtfRendering-gdi.dll</HintPath>
<Reference Include="MigraDoc.RtfRendering-gdi, Version=6.1.1.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\MigraDoc.RtfRendering-gdi.dll</HintPath>
</Reference>
<Reference Include="PdfSharp-gdi, Version=1.50.5147.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-gdi.1.50.5147\lib\net20\PdfSharp-gdi.dll</HintPath>
<Reference Include="PdfSharp-gdi, Version=6.1.1.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\PdfSharp-gdi.dll</HintPath>
</Reference>
<Reference Include="PdfSharp.Charting-gdi, Version=1.50.5147.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-gdi.1.50.5147\lib\net20\PdfSharp.Charting-gdi.dll</HintPath>
<Reference Include="PdfSharp.Charting-gdi, Version=6.1.1.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\PdfSharp.Charting-gdi.dll</HintPath>
</Reference>
<Reference Include="PdfSharp.Quality-gdi, Version=6.1.1.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\PdfSharp.Quality-gdi.dll</HintPath>
</Reference>
<Reference Include="PdfSharp.Snippets-gdi, Version=6.1.1.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\PdfSharp.Snippets-gdi.dll</HintPath>
</Reference>
<Reference Include="PdfSharp.System, Version=6.1.1.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\PdfSharp.System.dll</HintPath>
</Reference>
<Reference Include="PdfSharp.WPFonts, Version=6.1.1.0, Culture=neutral, PublicKeyToken=f94615aa0424f9eb, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\PdfSharp.WPFonts.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Buffers, Version=4.0.3.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\System.Buffers.dll</HintPath>
</Reference>
<Reference Include="System.ComponentModel.DataAnnotations" />
<Reference Include="System.Configuration" />
<Reference Include="System.Data" />
<Reference Include="System.Data.SQLite, Version=1.0.117.0, Culture=neutral, PublicKeyToken=db937bc2d44ff139, processorArchitecture=MSIL">
<HintPath>packages\Stub.System.Data.SQLite.Core.NetFramework.1.0.117.0\lib\net46\System.Data.SQLite.dll</HintPath>
</Reference>
<Reference Include="System.Diagnostics.DiagnosticSource, Version=8.0.0.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>packages\System.Diagnostics.DiagnosticSource.8.0.1\lib\net462\System.Diagnostics.DiagnosticSource.dll</HintPath>
</Reference>
<Reference Include="System.Drawing" />
<Reference Include="System.IO.Compression" />
<Reference Include="System.Memory, Version=4.0.1.2, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>packages\System.Memory.4.5.5\lib\net461\System.Memory.dll</HintPath>
</Reference>
<Reference Include="System.Numerics" />
<Reference Include="System.Numerics.Vectors, Version=4.1.4.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\System.Numerics.Vectors.dll</HintPath>
</Reference>
<Reference Include="System.Runtime.CompilerServices.Unsafe, Version=6.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\System.Runtime.CompilerServices.Unsafe.dll</HintPath>
</Reference>
<Reference Include="System.Runtime.Serialization" />
<Reference Include="System.ServiceModel" />
<Reference Include="System.ServiceModel.Web" />
<Reference Include="System.ServiceProcess" />
<Reference Include="System.Threading.Tasks.Extensions, Version=4.2.0.1, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\System.Threading.Tasks.Extensions.dll</HintPath>
</Reference>
<Reference Include="System.ValueTuple, Version=4.0.3.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51, processorArchitecture=MSIL">
<HintPath>packages\PDFsharp-MigraDoc-GDI.6.1.1\lib\net472\System.ValueTuple.dll</HintPath>
</Reference>
<Reference Include="System.Web" />
<Reference Include="System.Xml" />
<Reference Include="Microsoft.CSharp" />
@ -185,20 +242,20 @@
<Reference Include="WindowsBase" />
<Reference Include="PresentationCore" />
<Reference Include="PresentationFramework" />
<Reference Include="Xceed.Wpf.AvalonDock, Version=4.5.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.5.0\lib\net40\Xceed.Wpf.AvalonDock.dll</HintPath>
<Reference Include="Xceed.Wpf.AvalonDock, Version=4.6.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.6.1\lib\net40\Xceed.Wpf.AvalonDock.dll</HintPath>
</Reference>
<Reference Include="Xceed.Wpf.AvalonDock.Themes.Aero, Version=4.5.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.5.0\lib\net40\Xceed.Wpf.AvalonDock.Themes.Aero.dll</HintPath>
<Reference Include="Xceed.Wpf.AvalonDock.Themes.Aero, Version=4.6.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.6.1\lib\net40\Xceed.Wpf.AvalonDock.Themes.Aero.dll</HintPath>
</Reference>
<Reference Include="Xceed.Wpf.AvalonDock.Themes.Metro, Version=4.5.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.5.0\lib\net40\Xceed.Wpf.AvalonDock.Themes.Metro.dll</HintPath>
<Reference Include="Xceed.Wpf.AvalonDock.Themes.Metro, Version=4.6.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.6.1\lib\net40\Xceed.Wpf.AvalonDock.Themes.Metro.dll</HintPath>
</Reference>
<Reference Include="Xceed.Wpf.AvalonDock.Themes.VS2010, Version=4.5.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.5.0\lib\net40\Xceed.Wpf.AvalonDock.Themes.VS2010.dll</HintPath>
<Reference Include="Xceed.Wpf.AvalonDock.Themes.VS2010, Version=4.6.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.6.1\lib\net40\Xceed.Wpf.AvalonDock.Themes.VS2010.dll</HintPath>
</Reference>
<Reference Include="Xceed.Wpf.Toolkit, Version=4.5.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.5.0\lib\net40\Xceed.Wpf.Toolkit.dll</HintPath>
<Reference Include="Xceed.Wpf.Toolkit, Version=4.6.0.0, Culture=neutral, PublicKeyToken=3e4669d2f30244f4, processorArchitecture=MSIL">
<HintPath>packages\Extended.Wpf.Toolkit.4.6.1\lib\net40\Xceed.Wpf.Toolkit.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
@ -455,7 +512,9 @@
<Compile Include="Util\HighlightService.cs" />
<Compile Include="Util\InverseBooleanConverter.cs" />
<Compile Include="Util\NullImageConverter.cs" />
<Compile Include="Util\NumberValidationRule.cs" />
<Compile Include="Util\SettingBindingExtension.cs" />
<Compile Include="Util\StringValidationRule.cs" />
<Compile Include="Util\TrimStringConverter.cs" />
<Compile Include="Util\UIHelper.cs" />
<Compile Include="Util\UtcToLocalDateTimeConverter.cs" />
@ -924,9 +983,9 @@
<Resource Include="Resources\containership.ico" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.5.2">
<BootstrapperPackage Include=".NETFramework,Version=v4.8">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.5.2 %28x86 and x64%29</ProductName>
<ProductName>Microsoft .NET Framework 4.8 %28x86 and x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">

View File

@ -60,7 +60,7 @@
ButtonSpinnerLocation="Right"
ParsingNumberStyle="Integer"
Watermark="Enter ENI" ValueChanged="doubleUpDownENI_ValueChanged" TextAlignment="Left"/>
<enictrl:LocodeControl Grid.Column="1" Grid.Row="3" Grid.ColumnSpan="2" Width="Auto" x:Name="locodePoC" />
<enictrl:LocodeControl Grid.Column="1" Grid.Row="3" Grid.ColumnSpan="2" Width="Auto" x:Name="locodePoC" LocodeSource="OLD" />
<DatePicker Name="datePickerETA" Grid.Row="4" Grid.Column="1" Grid.ColumnSpan="2" SelectedDateChanged="datePickerETA_SelectedDateChanged" DisplayDateStart="1/1/1900" DisplayDateEnd="12/31/2199">
<DatePicker.BlackoutDates>
<CalendarDateRange Start="1/1/0001" End="12/31/1799"/>

View File

@ -57,7 +57,7 @@ namespace ENI2.EditControls
isComplete &= imo_OR_eni;
string locode = this.locodePoC.LocodeValue;
bool validLocode = (locode?.Length == 5) && (locode.StartsWith("DE") || locode.StartsWith("DK") || locode.Equals("ZZNOK"));
bool validLocode = (locode?.Length == 5) && (locode.StartsWith("DE") || locode.StartsWith("DK") || locode.Equals("ZZNOK") || locode.Equals("DEWHV"));
isComplete &= validLocode;

View File

@ -52,7 +52,7 @@
ButtonSpinnerLocation="Right"
ParsingNumberStyle="Integer"
Watermark="Enter ENI" ValueChanged="doubleUpDownENI_ValueChanged" TextAlignment="Left"/>
<enictrl:LocodeControl Grid.Column="1" Grid.Row="2" Width="Auto" x:Name="locodePoC" LocodeValue="{Binding PoC, Mode=TwoWay}" />
<enictrl:LocodeControl Grid.Column="1" Grid.Row="2" Width="Auto" x:Name="locodePoC" LocodeValue="{Binding PoC, Mode=TwoWay}" LocodeSource="OLD" />
<DatePicker Name="datePickerETA" Grid.Row="3" Grid.Column="1" Margin="2" SelectedDateChanged="datePickerETA_SelectedDateChanged" DisplayDateStart="1/1/1900" DisplayDateEnd="12/31/2199" PreviewKeyUp="DateTimePicker_PreviewKeyUpDate">
<DatePicker.BlackoutDates>
<CalendarDateRange Start="1/1/0001" End="12/31/1799"/>

View File

@ -133,7 +133,7 @@ namespace ENI2.EditControls
isComplete &= imo_OR_eni;
string locode = this.locodePoC.LocodeValue;
bool validLocode = (locode != null) && (locode.Length == 5) && (locode.StartsWith("DE") || locode.StartsWith("DK") || locode.Equals("ZZNOK"));
bool validLocode = (locode != null) && (locode.Length == 5) && (locode.StartsWith("DE") || locode.StartsWith("DK") || locode.Equals("ZZNOK") || locode.Equals("DEWHV"));
isComplete &= validLocode;

View File

@ -7,6 +7,7 @@ using Microsoft.Office.Interop.Excel;
using System.Runtime.InteropServices;
using log4net;
using System.Globalization;
using System.Text.RegularExpressions;
namespace ENI2.Excel
{
@ -105,6 +106,20 @@ namespace ENI2.Excel
}
}
private static double? ParseAnyDouble(string val)
{
double? result = null;
if (double.TryParse(val, NumberStyles.AllowDecimalPoint | NumberStyles.AllowLeadingWhite | NumberStyles.AllowTrailingWhite,
CultureInfo.InvariantCulture, out double tmpDouble))
result = tmpDouble;
if (result == null)
{
if (double.TryParse(val, out tmpDouble)) // current language style (==GER, mit , statt .)
result = tmpDouble;
}
return result;
}
internal double? ReadNumber(string lookup)
{
double? result = null;
@ -114,15 +129,17 @@ namespace ENI2.Excel
{
var val = _nameDict[lookup].RefersToRange.Value;
if (val is double) result = val;
if (val is string)
if ((val is string) && (val.Length > 0))
{
if (double.TryParse(val, NumberStyles.AllowDecimalPoint | NumberStyles.AllowLeadingWhite | NumberStyles.AllowTrailingWhite,
CultureInfo.InvariantCulture, out double tmpDouble))
result = tmpDouble;
result = ParseAnyDouble(val);
if(result == null)
{
if (double.TryParse(val, out tmpDouble)) // current language style (==GER, mit , statt .)
result = tmpDouble;
Match m = Regex.Match(val, "([0-9\\.\\,]+)([a-zA-Z]*)");
if (m.Success)
{
result = ParseAnyDouble(m.Groups[1].Value);
}
}
}

View File

@ -57,7 +57,7 @@ namespace ENI2.Excel
return false;
}
ValueMapping.LoadDicts(); // reload all messaging dicts (also removes "temporary" entries from last run)
Task.Run(async () => await ValueMapping.LoadDicts()); // reload all messaging dicts (also removes "temporary" entries from last run)
// load messages if already present
List<Message> messages = DBManager.Instance.GetMessagesForCore(messageCore, DBManager.MessageLoad.ALL);
@ -1898,8 +1898,6 @@ namespace ENI2.Excel
string tLen = string.Format("TOWD.TowageOnDepartureLengthOverall_MTR_{0}", i);
string tBeam = string.Format("TOWD.TowageOnDepartureBeam_MTR_{0}", i);
string tOp = string.Format("TOWD.TowageOnDepartureOperatorCompanyName_{0}", i);
string tPoc = string.Format("TOWD.TowageOnArrivalPurposeOfCall_{0}", i);
string tgt = string.Format("TOWD.TowageOnArrivalGrossTonnage_{0}", i);
string towageName = reader.ReadText(tName);
if (towageName.IsNullOrEmpty()) continue;

View File

@ -1433,6 +1433,15 @@ namespace ENI2.Properties {
}
}
/// <summary>
/// Looks up a localized string similar to This will delete all entries. Are you sure?.
/// </summary>
public static string textConfimDeleteAllEntries {
get {
return ResourceManager.GetString("textConfimDeleteAllEntries", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Confirmation.
/// </summary>
@ -1631,6 +1640,15 @@ namespace ENI2.Properties {
}
}
/// <summary>
/// Looks up a localized string similar to Copy ship name to clipboard.
/// </summary>
public static string textCopyShipnameClip {
get {
return ResourceManager.GetString("textCopyShipnameClip", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Copy to {0}.
/// </summary>
@ -1991,6 +2009,15 @@ namespace ENI2.Properties {
}
}
/// <summary>
/// Looks up a localized string similar to Delete all entries.
/// </summary>
public static string textDeleteAllEntries {
get {
return ResourceManager.GetString("textDeleteAllEntries", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Departure notification.
/// </summary>

View File

@ -1606,6 +1606,9 @@
<data name="textCopyClip" xml:space="preserve">
<value>Copy Id to clipboard</value>
</data>
<data name="textCopyShipnameClip" xml:space="preserve">
<value>Copy ship name to clipboard</value>
</data>
<data name="textUpdateStatus" xml:space="preserve">
<value>Server status update</value>
</data>
@ -1903,4 +1906,10 @@
<data name="textSpecialCaseDEHAM" xml:space="preserve">
<value>{0} has not been sent for DEHAM. Close anyway?</value>
</data>
<data name="textDeleteAllEntries" xml:space="preserve">
<value>Delete all entries</value>
</data>
<data name="textConfimDeleteAllEntries" xml:space="preserve">
<value>This will delete all entries. Are you sure?</value>
</data>
</root>

View File

@ -46,16 +46,25 @@ namespace ENI2
this.dataGrid.ContextMenu = new ContextMenu();
this.dataGrid.CanUserAddRows = false;
this.dataGrid.ContextMenuOpening += ContextMenu_ContextMenuOpening;
MenuItem addItem = new MenuItem();
addItem.Header = Properties.Resources.textCopyClip;
addItem.Icon = new Image { Source = new BitmapImage(new Uri("pack://application:,,,/Resources/documents.png")) };
addItem.Click += this.copyID;
this.dataGrid.ContextMenu.Items.Add(addItem);
MenuItem copyIMOItem = new MenuItem();
copyIMOItem.Header = Properties.Resources.textCopyIMO;
copyIMOItem.Icon = new Image { Source = new BitmapImage(new Uri("pack://application:,,,/Resources/document_into.png")) };
copyIMOItem.Click += this.copyIMO;
this.dataGrid.ContextMenu.Items.Add(copyIMOItem);
MenuItem copyShipnameItem = new MenuItem();
copyShipnameItem.Header = Properties.Resources.textCopyShipnameClip;
copyShipnameItem.Icon = new Image { Source = new BitmapImage(new Uri("pack://application:,,,/Resources/documents.png")) };
copyShipnameItem.Click += this.copyShipname;
this.dataGrid.ContextMenu.Items.Add(copyShipnameItem);
cancelItem = new MenuItem();
cancelItem.Header = Properties.Resources.textUndoCancel;
cancelItem.Icon = new Image { Source = new BitmapImage(new Uri("pack://application:,,,/Resources/delete.png")) };
@ -302,6 +311,17 @@ namespace ENI2
}
}
private void copyShipname(object sender, RoutedEventArgs e)
{
if (dataGrid.SelectedItem is MessageCore selectedCore)
{
if (selectedCore.Shipname != null)
{
Clipboard.SetText(selectedCore.Shipname);
}
}
}
private void copyIMO(object sender, RoutedEventArgs e)
{
if (dataGrid.SelectedItem is MessageCore selectedCore)

View File

@ -0,0 +1,32 @@
// Copyright (c) 2017- schick Informatik
// Description: Validation for direct in-grid editing
//
using System;
using System.Globalization;
using System.Windows.Controls;
namespace ENI2.Util
{
public class NumberValidationRule : ValidationRule
{
public double? MaxValue { get; set; }
public double MinValue { get; set; } = 0;
public override ValidationResult Validate(object value, CultureInfo cultureInfo)
{
if (!double.TryParse(Convert.ToString(value), out double aDouble))
return new ValidationResult(false, "Illegal characters");
if (((MaxValue != null) && (aDouble > MaxValue)) || (aDouble < MinValue))
{
return new ValidationResult(false, string.Format("Please enter a number in the range: {0} - {1}", MinValue, MaxValue));
}
else
{
return new ValidationResult(true, null);
}
}
}
}

View File

@ -0,0 +1,28 @@
// Copyright (c) 2017- schick Informatik
// Description: Validation for direct in-grid editing
//
using System.Globalization;
using System.Windows.Controls;
namespace ENI2.Util
{
public class StringValidationRule : ValidationRule
{
public int MaxLength { get; set; } = 100;
public override ValidationResult Validate(object value, CultureInfo cultureInfo)
{
if ((value is string text) && text.Length > MaxLength)
{
return new ValidationResult(false, string.Format("Text is longer than {0} chars", MaxLength));
}
else
{
return new ValidationResult(true, null);
}
}
}
}

View File

@ -3,11 +3,25 @@
Sample license text.
-->
<packages>
<package id="ExcelDataReader" version="3.6.0" targetFramework="net452" />
<package id="Extended.Wpf.Toolkit" version="4.5.0" targetFramework="net48" />
<package id="log4net" version="2.0.15" targetFramework="net48" />
<package id="ExcelDataReader" version="3.7.0" targetFramework="net48" />
<package id="Extended.Wpf.Toolkit" version="4.6.1" targetFramework="net48" />
<package id="log4net" version="3.0.1" targetFramework="net48" />
<package id="Microsoft.Bcl.AsyncInterfaces" version="8.0.0" targetFramework="net48" />
<package id="Microsoft.Extensions.DependencyInjection" version="8.0.1" targetFramework="net48" />
<package id="Microsoft.Extensions.DependencyInjection.Abstractions" version="8.0.2" targetFramework="net48" />
<package id="Microsoft.Extensions.Logging" version="8.0.1" targetFramework="net48" />
<package id="Microsoft.Extensions.Logging.Abstractions" version="8.0.2" targetFramework="net48" />
<package id="Microsoft.Extensions.Options" version="8.0.2" targetFramework="net48" />
<package id="Microsoft.Extensions.Primitives" version="8.0.0" targetFramework="net48" />
<package id="Microsoft.Office.Interop.Excel" version="15.0.4795.1001" targetFramework="net48" />
<package id="PDFsharp-MigraDoc-gdi" version="1.50.5147" targetFramework="net452" />
<package id="PDFsharp-MigraDoc-GDI" version="6.1.1" targetFramework="net48" />
<package id="Stub.System.Data.SQLite.Core.NetFramework" version="1.0.117.0" targetFramework="net48" />
<package id="System.Buffers" version="4.5.1" targetFramework="net48" />
<package id="System.Data.SQLite.Core" version="1.0.117.0" targetFramework="net48" />
<package id="System.Diagnostics.DiagnosticSource" version="8.0.1" targetFramework="net48" />
<package id="System.Memory" version="4.5.5" targetFramework="net48" />
<package id="System.Numerics.Vectors" version="4.5.0" targetFramework="net48" />
<package id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" targetFramework="net48" />
<package id="System.Threading.Tasks.Extensions" version="4.5.4" targetFramework="net48" />
<package id="System.ValueTuple" version="4.5.0" targetFramework="net48" />
</packages>

View File

@ -274,14 +274,15 @@ namespace SendNSWMessageService
}
// external processing for HIS-Nord
if (bsmd.hisnord.transmitter.Transmit())
// HIS-Nord --------------------------------------------------
if (bsmd.hisnord.transmitter.Transmit()) // run process (transmit+receive)
{
bsmd.hisnord.Request.ReadResponseFiles();
bsmd.hisnord.Response.ReadAnswers();
}
// external processing for dbh
// dbh -------------------------------------------------------
bsmd.dbh.MessageController.SendAndReceive();
foreach (MessageCore core in DBManager.Instance.GetMessageCoresWithNSWStatusFlag())

View File

@ -40,8 +40,8 @@
<AssemblyOriginatorKeyFile>..\bsmdKey.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<ItemGroup>
<Reference Include="log4net, Version=2.0.16.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.16\lib\net45\log4net.dll</HintPath>
<Reference Include="log4net, Version=2.0.17.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.17\lib\net45\log4net.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="log4net" version="2.0.16" targetFramework="net48" />
<package id="log4net" version="2.0.17" targetFramework="net48" />
</packages>

View File

@ -46,8 +46,8 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="log4net, Version=2.0.15.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\ENI2\packages\log4net.2.0.15\lib\net45\log4net.dll</HintPath>
<Reference Include="log4net, Version=3.0.1.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\ENI2\packages\log4net.3.0.1\lib\net462\log4net.dll</HintPath>
</Reference>
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data.DataSetExtensions" />

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="log4net" version="2.0.15" targetFramework="net48" />
<package id="log4net" version="3.0.1" targetFramework="net48" />
</packages>

View File

@ -40,8 +40,8 @@
<AssemblyOriginatorKeyFile>..\bsmdKey.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<ItemGroup>
<Reference Include="log4net, Version=2.0.16.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.16\lib\net45\log4net.dll</HintPath>
<Reference Include="log4net, Version=2.0.17.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.17\lib\net45\log4net.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />
@ -52,8 +52,8 @@
<Reference Include="Microsoft.CSharp" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
<Reference Include="WinSCPnet, Version=1.15.0.14890, Culture=neutral, PublicKeyToken=2271ec4a3c56d0bf, processorArchitecture=MSIL">
<HintPath>..\packages\WinSCP.6.3.2\lib\net40\WinSCPnet.dll</HintPath>
<Reference Include="WinSCPnet, Version=1.15.0.14955, Culture=neutral, PublicKeyToken=2271ec4a3c56d0bf, processorArchitecture=MSIL">
<HintPath>..\packages\WinSCP.6.3.4\lib\net40\WinSCPnet.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
@ -93,12 +93,12 @@
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<Import Project="..\packages\WinSCP.6.3.2\build\WinSCP.targets" Condition="Exists('..\packages\WinSCP.6.3.2\build\WinSCP.targets')" />
<Import Project="..\packages\WinSCP.6.3.4\build\WinSCP.targets" Condition="Exists('..\packages\WinSCP.6.3.4\build\WinSCP.targets')" />
<Target Name="EnsureNuGetPackageBuildImports" BeforeTargets="PrepareForBuild">
<PropertyGroup>
<ErrorText>This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}.</ErrorText>
</PropertyGroup>
<Error Condition="!Exists('..\packages\WinSCP.6.3.2\build\WinSCP.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\WinSCP.6.3.2\build\WinSCP.targets'))" />
<Error Condition="!Exists('..\packages\WinSCP.6.3.4\build\WinSCP.targets')" Text="$([System.String]::Format('$(ErrorText)', '..\packages\WinSCP.6.3.4\build\WinSCP.targets'))" />
</Target>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="log4net" version="2.0.16" targetFramework="net48" />
<package id="WinSCP" version="6.3.2" targetFramework="net48" />
<package id="log4net" version="2.0.17" targetFramework="net48" />
<package id="WinSCP" version="6.3.4" targetFramework="net48" />
</packages>

View File

@ -459,6 +459,135 @@ namespace bsmd.database
#endregion
#region public static helper funcs
public static CREW CreateCommon(List<CREW> crewList)
{
CREW crew = new CREW(); // template entity
if(crewList.IsNullOrEmpty())
return crew;
string crewMemberLastName = crewList[0].CrewMemberLastName;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberLastName, crewMemberLastName)))
crew.CrewMemberLastName = crewMemberLastName;
string crewMemberFirstName = crewList[0].CrewMemberFirstName;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberFirstName, crewMemberFirstName)))
crew.CrewMemberFirstName = crewMemberFirstName;
string crewMemberPlaceOfBirth = crewList[0].CrewMemberPlaceOfBirth;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberPlaceOfBirth, crewMemberPlaceOfBirth)))
crew.CrewMemberPlaceOfBirth = crewMemberPlaceOfBirth;
string crewMemberCountryOfBirth = crewList[0].CrewMemberCountryOfBirth;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberPlaceOfBirth, crewMemberCountryOfBirth)))
crew.CrewMemberCountryOfBirth = crewMemberCountryOfBirth;
DateTime? crewMemberDateOfBirth = crewList[0].CrewMemberDateOfBirth;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberDateOfBirth, crewMemberDateOfBirth)))
crew.CrewMemberDateOfBirth = crewMemberDateOfBirth;
byte? crewMemberGender = crewList[0].CrewMemberGender;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberGender, crewMemberGender)))
crew.CrewMemberGender = crewMemberGender;
string crewMemberNationality = crewList[0].CrewMemberNationality;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberNationality, crewMemberNationality)))
crew.CrewMemberNationality = crewMemberNationality;
byte? crewMemberIdentityDocumentType = crewList[0].CrewMemberIdentityDocumentType;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberIdentityDocumentType, crewMemberIdentityDocumentType)))
crew.CrewMemberIdentityDocumentType = crewMemberIdentityDocumentType;
string crewMemberIdentityDocumentId = crewList[0].CrewMemberIdentityDocumentId;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberIdentityDocumentId, crewMemberIdentityDocumentId)))
crew.CrewMemberIdentityDocumentId = crewMemberIdentityDocumentId;
string crewMemberVisaNumber = crewList[0].CrewMemberVisaNumber;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberVisaNumber, crewMemberVisaNumber)))
crew.CrewMemberVisaNumber = crewMemberVisaNumber;
string crewMemberDuty = crewList[0].CrewMemberDuty;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberDuty, crewMemberDuty)))
crew.CrewMemberDuty = crewMemberDuty;
string crewMemberIdentityDocumentIssuingState = crewList[0].CrewMemberIdentityDocumentIssuingState;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberIdentityDocumentIssuingState, crewMemberIdentityDocumentIssuingState)))
crew.CrewMemberIdentityDocumentIssuingState = crewMemberIdentityDocumentIssuingState;
DateTime? crewMemberIdentityDocumentExpiryDate = crewList[0].CrewMemberIdentityDocumentExpiryDate;
if (crewList.All(x => Extensions.AreEqual(x.CrewMemberIdentityDocumentExpiryDate, crewMemberIdentityDocumentExpiryDate)))
crew.CrewMemberIdentityDocumentExpiryDate = crewMemberIdentityDocumentExpiryDate;
string effects = crewList[0].Effects;
if (crewList.All(x => Extensions.AreEqual(x.Effects, effects)))
crew.Effects = effects;
bool? notificationPax = crewList[0].NotificationPAX;
if (crewList.All(x => Extensions.AreEqual(x.NotificationPAX, notificationPax)))
crew.NotificationPAX = notificationPax;
bool? notificationSchengen = crewList[0].NotificationSchengen;
if (crewList.All(x => Extensions.AreEqual(x.NotificationSchengen, notificationSchengen)))
crew.NotificationSchengen = notificationSchengen;
return crew;
}
public static void WriteTemplateToList(CREW crew, List<CREW> crewList)
{
if (!crew.CrewMemberLastName.IsNullOrEmpty())
crewList.ForEach(x => x.CrewMemberLastName = crew.CrewMemberLastName);
if (!crew.CrewMemberFirstName.IsNullOrEmpty())
crewList.ForEach(x => x.CrewMemberFirstName = crew.CrewMemberFirstName);
if (!crew.CrewMemberPlaceOfBirth.IsNullOrEmpty())
crewList.ForEach(x => x.CrewMemberPlaceOfBirth = crew.CrewMemberPlaceOfBirth);
if (!crew.CrewMemberCountryOfBirth.IsNullOrEmpty())
crewList.ForEach(x => x.CrewMemberCountryOfBirth = crew.CrewMemberCountryOfBirth);
if (crew.CrewMemberDateOfBirth != null)
crewList.ForEach(x => x.CrewMemberDateOfBirth = crew.CrewMemberDateOfBirth);
if (crew.CrewMemberGender != null)
crewList.ForEach(x => x.CrewMemberGender = crew.CrewMemberGender);
if (!crew.CrewMemberNationality.IsNullOrEmpty())
crewList.ForEach(x => x.CrewMemberNationality = crew.CrewMemberNationality);
if (crew.CrewMemberIdentityDocumentType != null)
crewList.ForEach(x => x.CrewMemberIdentityDocumentType = crew.CrewMemberIdentityDocumentType);
if (!crew.CrewMemberIdentityDocumentId.IsNullOrEmpty())
crewList.ForEach(x => x.CrewMemberIdentityDocumentId = crew.CrewMemberIdentityDocumentId);
if (!crew.CrewMemberVisaNumber.IsNullOrEmpty())
crewList.ForEach(x => x.CrewMemberVisaNumber = crew.CrewMemberVisaNumber);
if (!crew.CrewMemberDuty.IsNullOrEmpty())
crewList.ForEach(x => x.CrewMemberDuty = crew.CrewMemberDuty);
if (!crew.CrewMemberIdentityDocumentIssuingState.IsNullOrEmpty())
crewList.ForEach(x => x.CrewMemberIdentityDocumentIssuingState = crew.CrewMemberIdentityDocumentIssuingState);
if (crew.CrewMemberIdentityDocumentExpiryDate != null)
crewList.ForEach(x => x.CrewMemberIdentityDocumentExpiryDate = crew.CrewMemberIdentityDocumentExpiryDate);
if (!crew.Effects.IsNullOrEmpty())
crewList.ForEach(x => x.Effects = crew.Effects);
if (crew.NotificationPAX != null)
crewList.ForEach(x => x.NotificationPAX = crew.NotificationPAX);
if (crew.NotificationSchengen != null)
crewList.ForEach(x => x.NotificationSchengen = crew.NotificationSchengen);
}
#endregion
}
#region CREWD

View File

@ -36,6 +36,33 @@ namespace bsmd.database
return false;
}
public static bool AreEqual(string a, string b)
{
if (string.IsNullOrEmpty(a)) return string.IsNullOrEmpty(b);
return string.Equals(a, b);
}
public static bool AreEqual(DateTime? a, DateTime? b)
{
if(!a.HasValue) return !b.HasValue;
if(!b.HasValue) return !a.HasValue;
return a.Value.Equals(b.Value);
}
public static bool AreEqual(byte? a, byte? b)
{
if (!a.HasValue) return !b.HasValue;
if (!b.HasValue) return !a.HasValue;
return a.Value.Equals(b.Value);
}
public static bool AreEqual(bool? a, bool? b)
{
if (!a.HasValue) return !b.HasValue;
if (!b.HasValue) return !a.HasValue;
return a.Value == b.Value;
}
public static bool IsNullOrEmpty<T>(this List<T> items)
{
return (items == null) || (items.Count == 0);

View File

@ -521,6 +521,157 @@ namespace bsmd.database
}
#endregion
#region public static helper funcs
public static PAS CreateCommon(List<PAS> pasList)
{
PAS pas = new PAS(); // template entity
//
if (pasList.IsNullOrEmpty())
return pas;
string passengerLastName = pasList[0].PassengerLastName;
if (pasList.All(x => Extensions.AreEqual(x.PassengerLastName, passengerLastName)))
pas.PassengerLastName = passengerLastName;
string passengerFirstName = pasList[0].PassengerFirstName;
if(pasList.All(x => Extensions.AreEqual(x.PassengerFirstName, passengerFirstName)))
pas.PassengerFirstName = passengerFirstName;
string passengerPlaceOfBirth = pasList[0].PassengerPlaceOfBirth;
if(pasList.All(x => Extensions.AreEqual(x.PassengerPlaceOfBirth, passengerPlaceOfBirth)))
pas.PassengerPlaceOfBirth = passengerPlaceOfBirth;
DateTime? passengerDateOfBirth = pasList[0].PassengerDateOfBirth;
if(pasList.All(x => Extensions.AreEqual(x.PassengerDateOfBirth, passengerDateOfBirth)))
pas.PassengerDateOfBirth = passengerDateOfBirth;
byte? passengerGender = pasList[0].PassengerGender;
if(pasList.All(x => Extensions.AreEqual(x.PassengerGender, passengerGender)))
pas.PassengerGender = passengerGender;
string passengerNationality = pasList[0].PassengerNationality;
if(pasList.All(x => Extensions.AreEqual(x.PassengerNationality, passengerNationality)))
pas.PassengerNationality = passengerNationality;
byte? passengerIdentityDocumentType = pasList[0].PassengerIdentityDocumentType;
if(pasList.All(x => Extensions.AreEqual(x.PassengerIdentityDocumentType, passengerIdentityDocumentType)))
pas.PassengerIdentityDocumentType = passengerIdentityDocumentType;
string passengerIdentityDocumentId = pasList[0].PassengerIdentityDocumentId;
if(pasList.All(x => Extensions.AreEqual(x.PassengerIdentityDocumentId, passengerIdentityDocumentId)))
pas.PassengerIdentityDocumentId = passengerIdentityDocumentId;
string passengerVisaNumber = pasList[0].PassengerVisaNumber;
if(pasList.All(x => Extensions.AreEqual(x.PassengerVisaNumber, passengerVisaNumber)))
pas.PassengerVisaNumber = passengerVisaNumber;
string passengerPortOfEmbarkation = pasList[0].PassengerPortOfEmbarkation;
if (pasList.All(x => Extensions.AreEqual(x.PassengerPortOfEmbarkation, passengerPortOfEmbarkation)))
pas.PassengerPortOfEmbarkation = passengerPortOfEmbarkation;
string passengerPortOfDisembarkation = pasList[0].PassengerPortOfDisembarkation;
if(pasList.All(x => Extensions.AreEqual(x.PassengerPortOfDisembarkation, passengerPortOfDisembarkation)))
pas.PassengerPortOfDisembarkation = passengerPortOfDisembarkation;
bool? passengerInTransit = pasList[0].PassengerInTransit;
if(pasList.All(x => Extensions.AreEqual(x.PassengerInTransit, passengerInTransit)))
pas.PassengerInTransit = passengerInTransit;
string passengerIdentityDocumentIssuingState = pasList[0].PassengerIdentityDocumentIssuingState;
if(pasList.All(x => Extensions.AreEqual(x.PassengerIdentityDocumentIssuingState, passengerIdentityDocumentIssuingState)))
pas.PassengerIdentityDocumentIssuingState = passengerIdentityDocumentIssuingState;
DateTime? passengerIdentityDocumentExpiryDate = pasList[0].PassengerIdentityDocumentExpiryDate;
if(pasList.All(x => Extensions.AreEqual(x.PassengerIdentityDocumentExpiryDate, passengerIdentityDocumentExpiryDate)))
pas.PassengerIdentityDocumentExpiryDate = passengerIdentityDocumentExpiryDate;
bool? notificationSchengen = pasList[0].NotificationSchengen;
if(pasList.All(x => Extensions.AreEqual(x.NotificationSchengen, notificationSchengen)))
pas.NotificationSchengen = notificationSchengen;
bool? notificationPAX = pasList[0].NotificationPAX;
if(pasList.All(x => Extensions.AreEqual(x.NotificationPAX, notificationPAX)))
pas.NotificationPAX = notificationPAX;
string passengerCountryOfBirth = pasList[0].PassengerCountryOfBirth;
if(pasList.All(x => Extensions.AreEqual(x.PassengerCountryOfBirth, passengerCountryOfBirth)))
pas.PassengerCountryOfBirth = passengerCountryOfBirth;
string emergencyCare = pasList[0].EmergencyCare;
if(pasList.All(x => Extensions.AreEqual(x.EmergencyCare, emergencyCare)))
pas.EmergencyCare = emergencyCare;
string emergencyContactNumber = pasList[0].EmergencyContactNumber;
if(pasList.All(x => Extensions.AreEqual(x.EmergencyContactNumber, emergencyContactNumber)))
pas.EmergencyContactNumber = emergencyContactNumber;
return pas;
}
public static void WriteTemplateToList(PAS pas, List<PAS> pasList)
{
if (!pas.PassengerLastName.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerLastName = pas.PassengerLastName);
if (!pas.PassengerFirstName.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerFirstName = pas.PassengerFirstName);
if(!pas.PassengerPlaceOfBirth.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerPlaceOfBirth = pas.PassengerPlaceOfBirth);
if(pas.PassengerDateOfBirth.HasValue)
pasList.ForEach(x => x.PassengerDateOfBirth = pas.PassengerDateOfBirth.Value);
if(pas.PassengerGender.HasValue)
pasList.ForEach(x => x.PassengerGender = pas.PassengerGender.Value);
if(!pas.PassengerNationality.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerNationality = pas.PassengerNationality);
if(pas.PassengerIdentityDocumentType.HasValue)
pasList.ForEach(x => x.PassengerIdentityDocumentType = pas.PassengerIdentityDocumentType.Value);
if(!pas.PassengerIdentityDocumentId.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerIdentityDocumentId = pas.PassengerIdentityDocumentId);
if(!pas.PassengerVisaNumber.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerVisaNumber = pas.PassengerVisaNumber);
if(!pas.PassengerPortOfEmbarkation.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerPortOfEmbarkation = pas.PassengerPortOfEmbarkation);
if(!pas.PassengerPortOfDisembarkation.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerPortOfDisembarkation = pas.PassengerPortOfDisembarkation);
if(pas.PassengerInTransit.HasValue)
pasList.ForEach(x => x.PassengerInTransit = pas.PassengerInTransit.Value);
if(!pas.PassengerIdentityDocumentIssuingState.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerIdentityDocumentIssuingState = pas.PassengerIdentityDocumentIssuingState);
if(pas.PassengerIdentityDocumentExpiryDate.HasValue)
pasList.ForEach(x => x.PassengerIdentityDocumentExpiryDate = pas.PassengerIdentityDocumentExpiryDate.Value);
if(pas.NotificationSchengen.HasValue)
pasList.ForEach(x => x.NotificationSchengen = pas.NotificationSchengen.Value);
if(pas.NotificationPAX.HasValue)
pasList.ForEach(x => x.NotificationPAX = pas.NotificationPAX.Value);
if(!pas.PassengerCountryOfBirth.IsNullOrEmpty())
pasList.ForEach(x => x.PassengerCountryOfBirth = pas.PassengerCountryOfBirth);
if(!pas.EmergencyCare.IsNullOrEmpty())
pasList.ForEach(x => x.EmergencyCare = pas.EmergencyCare);
if(!pas.EmergencyContactNumber.IsNullOrEmpty())
pasList.ForEach(x => x.EmergencyContactNumber = pas.EmergencyContactNumber);
}
#endregion
}
#region class PASD

View File

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

View File

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

View File

@ -101,7 +101,8 @@ namespace bsmd.database
{
STANDARD,
NO_PORT_FLAG,
SSN
SSN,
OLD // STANDARD + strange codes
};
public delegate bool LocodeValidHandler(string locode, LocodeMode mode);

View File

@ -180,7 +180,7 @@ namespace bsmd.database
/// <summary>
/// (re-)loads all value mapping dictionaries
/// </summary>
public static async void LoadDicts()
public static async Task LoadDicts()
{
foreach(MappingType type in Enum.GetValues(typeof(MappingType)))
{

View File

@ -25,6 +25,7 @@
<WarningLevel>4</WarningLevel>
<UseVSHostingProcess>false</UseVSHostingProcess>
<CodeAnalysisRuleSet>..\code.ruleset</CodeAnalysisRuleSet>
<UseWinFormsOutOfProcDesigner>False</UseWinFormsOutOfProcDesigner>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
@ -33,6 +34,7 @@
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<UseWinFormsOutOfProcDesigner>False</UseWinFormsOutOfProcDesigner>
</PropertyGroup>
<PropertyGroup>
<SignAssembly>true</SignAssembly>
@ -50,6 +52,7 @@
<LangVersion>7.3</LangVersion>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>..\code.ruleset</CodeAnalysisRuleSet>
<UseWinFormsOutOfProcDesigner>False</UseWinFormsOutOfProcDesigner>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
<DebugSymbols>true</DebugSymbols>
@ -61,6 +64,7 @@
<LangVersion>7.3</LangVersion>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>..\code.ruleset</CodeAnalysisRuleSet>
<UseWinFormsOutOfProcDesigner>False</UseWinFormsOutOfProcDesigner>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
<OutputPath>bin\x64\Release\</OutputPath>
@ -70,6 +74,7 @@
<PlatformTarget>x64</PlatformTarget>
<LangVersion>7.3</LangVersion>
<ErrorReport>prompt</ErrorReport>
<UseWinFormsOutOfProcDesigner>False</UseWinFormsOutOfProcDesigner>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug 64|x64'">
<DebugSymbols>true</DebugSymbols>
@ -81,10 +86,11 @@
<LangVersion>7.3</LangVersion>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>..\code.ruleset</CodeAnalysisRuleSet>
<UseWinFormsOutOfProcDesigner>False</UseWinFormsOutOfProcDesigner>
</PropertyGroup>
<ItemGroup>
<Reference Include="log4net, Version=2.0.15.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\ENI2\packages\log4net.2.0.15\lib\net45\log4net.dll</HintPath>
<Reference Include="log4net, Version=3.0.1.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\ENI2\packages\log4net.3.0.1\lib\net462\log4net.dll</HintPath>
</Reference>
<Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
<HintPath>..\ENI2\packages\Newtonsoft.Json.13.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="log4net" version="2.0.15" targetFramework="net48" />
<package id="log4net" version="3.0.1" targetFramework="net48" />
<package id="Newtonsoft.Json" version="13.0.3" targetFramework="net48" />
</packages>

View File

@ -4,6 +4,7 @@
using bsmd.database;
using log4net;
using System;
using System.Collections.Generic;
using System.IO;
using System.Text.RegularExpressions;
using System.Xml.Serialization;
@ -186,9 +187,21 @@ namespace bsmd.dbh
DBManager.Instance.Save(sentMessage);
if (!(aCore.Cancelled ?? false))
// das hier ist too easy, der Core kann nur auf RESPONDED gehen wenn nichts mehr auf TOSEND
// oder error steht
List<Message> messages = DBManager.Instance.GetMessagesForCore(aCore, DBManager.MessageLoad.ALL);
bool somethingStillInToSend = false;
foreach (Message message in messages)
{
if((message.InternalStatus == Message.BSMDStatus.TOSEND) ||
(message.InternalStatus == Message.BSMDStatus.SENT))
somethingStillInToSend = true;
}
if (!(aCore.Cancelled ?? false) && !somethingStillInToSend)
aCore.BSMDStatusInternal = MessageCore.BSMDStatus.RESPONDED;
_log.InfoFormat("Core {0} set to status {1}", aCore.DisplayId, aCore.BSMDStatusInternal);
DBManager.Instance.Save(aCore);
result = true;
}

View File

@ -38,8 +38,8 @@
<AssemblyOriginatorKeyFile>..\bsmdKey.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<ItemGroup>
<Reference Include="log4net, Version=2.0.16.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.16\lib\net45\log4net.dll</HintPath>
<Reference Include="log4net, Version=2.0.17.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.17\lib\net45\log4net.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="log4net" version="2.0.16" targetFramework="net48" />
<package id="log4net" version="2.0.17" targetFramework="net48" />
</packages>

View File

@ -12,7 +12,7 @@ namespace bsmd.hisnord.Properties {
[global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.10.0.0")]
[global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "17.10.0.0")]
public sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
@ -50,15 +50,6 @@ namespace bsmd.hisnord.Properties {
}
}
[global::System.Configuration.ApplicationScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("Transmitter-Tool\\RESULTS")]
public string ResultDir {
get {
return ((string)(this["ResultDir"]));
}
}
[global::System.Configuration.ApplicationScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("Transmitter-Tool\\ANSWERS")]
@ -94,5 +85,14 @@ namespace bsmd.hisnord.Properties {
return ((string)(this["TransmitterRoot"]));
}
}
[global::System.Configuration.ApplicationScopedSettingAttribute()]
[global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
[global::System.Configuration.DefaultSettingValueAttribute("Transmitter-Tool\\archive")]
public string OutputArchiveDir {
get {
return ((string)(this["OutputArchiveDir"]));
}
}
}
}

View File

@ -11,9 +11,6 @@
<Setting Name="Transmitter" Type="System.String" Scope="Application">
<Value Profile="(Default)">Transmitter-Tool\client.bat</Value>
</Setting>
<Setting Name="ResultDir" Type="System.String" Scope="Application">
<Value Profile="(Default)">Transmitter-Tool\RESULTS</Value>
</Setting>
<Setting Name="AnswerDir" Type="System.String" Scope="Application">
<Value Profile="(Default)">Transmitter-Tool\ANSWERS</Value>
</Setting>
@ -26,5 +23,8 @@
<Setting Name="TransmitterRoot" Type="System.String" Scope="Application">
<Value Profile="(Default)">E:\svnlager\BSMD\nsw\HIS-NORD\</Value>
</Setting>
<Setting Name="OutputArchiveDir" Type="System.String" Scope="Application">
<Value Profile="(Default)">Transmitter-Tool\archive</Value>
</Setting>
</Settings>
</SettingsFile>

View File

@ -10,7 +10,6 @@
using System;
using System.Collections.Generic;
using System.IO;
using System.Xml;
using System.Xml.Serialization;
using log4net;
using bsmd.database;
@ -21,7 +20,7 @@ namespace bsmd.hisnord
{
private static readonly ILog _log = LogManager.GetLogger(typeof(Request));
private static Dictionary<Guid, ReportingParty> _reportingPartyDict = null;
private static readonly Dictionary<MessageCore, Dictionary<Message, string>> coreFilenameDict = new Dictionary<MessageCore, Dictionary<Message,string>>();
// private static readonly Dictionary<MessageCore, Dictionary<Message, string>> coreFilenameDict = new Dictionary<MessageCore, Dictionary<Message,string>>();
internal static Dictionary<Guid, ReportingParty> ReportingPartyDict
{
@ -31,6 +30,8 @@ namespace bsmd.hisnord
}
}
/*
public static void ReadResponseFiles()
{
foreach (MessageCore core in coreFilenameDict.Keys)
@ -72,9 +73,10 @@ namespace bsmd.hisnord
{
coreFilenameDict[core].Remove(removeMessage);
}
}
}
}
}
*/
#region Create message file to send
@ -1815,11 +1817,6 @@ namespace bsmd.hisnord
serializer.Serialize(tw, _nsw);
}
if (!coreFilenameDict.ContainsKey(core))
coreFilenameDict[core] = new Dictionary<Message, string>();
if(message != null)
coreFilenameDict[core][message] = filename;
retval = true;
MessageTelemetry.Enqueue(Message.NSWProvider.DUDR, message);

View File

@ -1,4 +1,4 @@
// Copyright (c) 2015-2017 schick Informatik
// Copyright (c) 2015- schick Informatik
// Description: Bearbeitung von Antworten (dateibasiert..)
using bsmd.database;
@ -300,10 +300,12 @@ namespace bsmd.hisnord
{
// archive file
string answerArchiveDir = Path.Combine(Properties.Settings.Default.TransmitterRoot, Properties.Settings.Default.AnswerArchiveDir);
string archiveFile = Path.Combine(answerArchiveDir, Path.GetFileName(answerFile));
try
{
File.Move(answerFile, Path.Combine(answerArchiveDir, Path.GetFileName(answerFile)));
if(File.Exists(archiveFile))
File.Delete(archiveFile);
File.Move(answerFile, archiveFile);
}
catch(Exception ex)
{

View File

@ -16,9 +16,6 @@
<setting name="Transmitter" serializeAs="String">
<value>Transmitter-Tool\client.bat</value>
</setting>
<setting name="ResultDir" serializeAs="String">
<value>Transmitter-Tool\RESULTS</value>
</setting>
<setting name="AnswerDir" serializeAs="String">
<value>Transmitter-Tool\ANSWERS</value>
</setting>
@ -31,6 +28,9 @@
<setting name="TransmitterRoot" serializeAs="String">
<value>E:\svnlager\BSMD\nsw\HIS-NORD\</value>
</setting>
<setting name="OutputArchiveDir" serializeAs="String">
<value>Transmitter-Tool\archive</value>
</setting>
</bsmd.hisnord.Properties.Settings>
</applicationSettings>
</configuration>

View File

@ -38,8 +38,8 @@
<AssemblyOriginatorKeyFile>..\bsmdKey.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<ItemGroup>
<Reference Include="log4net, Version=2.0.16.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.16\lib\net45\log4net.dll</HintPath>
<Reference Include="log4net, Version=2.0.17.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.17\lib\net45\log4net.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="log4net" version="2.0.16" targetFramework="net48" />
<package id="log4net" version="2.0.17" targetFramework="net48" />
</packages>

View File

@ -10,8 +10,6 @@
using System;
using System.Diagnostics;
using System.IO;
using System.Threading.Tasks;
using System.Xml.Serialization;
using bsmd.database;
using log4net;
@ -32,15 +30,15 @@ namespace bsmd.hisnord
return false;
}
try
{
ProcessStartInfo startInfo = new ProcessStartInfo(Path.Combine(rootDir, Properties.Settings.Default.Transmitter));
startInfo.WorkingDirectory = rootDir;
startInfo.RedirectStandardError = true;
startInfo.RedirectStandardOutput = true;
startInfo.RedirectStandardInput = false;
startInfo.UseShellExecute = false;
// der Transmitter schickt alles was im Ausgabe-Verzeichnis ist
// damit das gut geht schicken wir die Nachrichten einzeln und arbeiten jeweils das
// Ergebnis ab
using (Process transmitterProcess = new Process())
{
@ -80,6 +78,12 @@ namespace bsmd.hisnord
}
return true;
}
catch (Exception ex)
{
_log.Error($"Transmitter failed: {ex.Message}");
return false;
}
}
private static void TransmitterProcess_OutputDataReceived(object sender, DataReceivedEventArgs e)
{
@ -89,8 +93,9 @@ namespace bsmd.hisnord
private static void TransmitterProcess_ErrorDataReceived(object sender, DataReceivedEventArgs e)
{
// Output of STDERR. HIS-Nord seems to be using this for logging, so we do not flag as error.
if(!e.Data.IsNullOrEmpty())
_log.Error(e.Data);
_log.Debug(e.Data);
}
private static void TransmitterProcess_Exited(object sender, EventArgs e)
@ -99,20 +104,11 @@ namespace bsmd.hisnord
processId = null;
}
public static result GetResult(string filenameFullPath)
{
// now we should read the response message...
string resultFilename = string.Format("{0}.result.xml", Path.GetFileName(filenameFullPath));
string resultDir = Path.Combine(Properties.Settings.Default.TransmitterRoot, Properties.Settings.Default.ResultDir);
string resultFullPath = Path.Combine(resultDir, resultFilename);
return result.ReadResult(resultFullPath);
}
public static void PurgeOldFiles(int maxAgeDays)
{
try
{
// "ANSWERS_DONE"
// "import_done" (= successfully received)
DirectoryInfo info = new DirectoryInfo(Path.Combine(Properties.Settings.Default.TransmitterRoot, Properties.Settings.Default.AnswerArchiveDir));
FileInfo[] files = info.GetFiles();
int cnt = 0;
@ -127,9 +123,9 @@ namespace bsmd.hisnord
}
_log.Info($"deleted {cnt} files from {Properties.Settings.Default.AnswerArchiveDir}");
// "RESULTS"
// "archive" (= successfully sent)
cnt = 0;
info = new DirectoryInfo(Path.Combine(Properties.Settings.Default.TransmitterRoot, Properties.Settings.Default.ResultDir));
info = new DirectoryInfo(Path.Combine(Properties.Settings.Default.TransmitterRoot, Properties.Settings.Default.OutputArchiveDir));
files = info.GetFiles();
foreach (FileInfo file in files)
{
@ -140,67 +136,13 @@ namespace bsmd.hisnord
cnt++;
}
}
_log.Info($"deleted {cnt} files from {Properties.Settings.Default.ResultDir}");
_log.Info($"deleted {cnt} files from {Properties.Settings.Default.OutputArchiveDir}");
// "READY"
cnt = 0;
info = new DirectoryInfo(Path.Combine(Properties.Settings.Default.TransmitterRoot, "READY"));
files = info.GetFiles();
foreach (FileInfo file in files)
{
if (file.CreationTime < DateTime.Now.AddDays(-maxAgeDays))
{
_log.Debug($"deleting {file.Name}");
file.Delete();
cnt++;
}
}
_log.Info($"deleted {cnt} files from READY");
}
catch(Exception ex)
{
_log.ErrorFormat("Error trying to delete old files: {0}", ex.Message);
}
}
/// <summary>
/// class to read transmitter result xml files
/// </summary>
[Serializable]
public class result
{
public result() { }
public int code { get; set; }
public string message { get; set; }
public string detail { get; set; }
/// <summary>
/// create result items from file
/// </summary>
public static result ReadResult(string filename)
{
result aResult = null;
try
{
XmlSerializer serializer = new XmlSerializer(typeof(result));
if (!File.Exists(filename))
{
_log.WarnFormat("Expected file {0} does not exist!", filename);
}
else
{
using (FileStream fs = new FileStream(filename, FileMode.Open))
{
aResult = (result)serializer.Deserialize(fs);
}
}
}
catch (Exception ex)
{
_log.ErrorFormat("Exception deserializing transmitter result: {0}", ex.Message);
}
return aResult;
}
}
}
}

View File

@ -38,8 +38,8 @@
<AssemblyOriginatorKeyFile>..\bsmdKey.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
<ItemGroup>
<Reference Include="log4net, Version=2.0.16.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.16\lib\net45\log4net.dll</HintPath>
<Reference Include="log4net, Version=2.0.17.0, Culture=neutral, PublicKeyToken=669e0ddf0bb1aa2a, processorArchitecture=MSIL">
<HintPath>..\packages\log4net.2.0.17\lib\net45\log4net.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Configuration" />

View File

@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="log4net" version="2.0.16" targetFramework="net48" />
<package id="log4net" version="2.0.17" targetFramework="net48" />
</packages>

View File

@ -8,29 +8,30 @@ Alcoholic beverages, n.o.s. (Wine);;;;; ;IBC;;;;;;;;x (Z);2;;;;
Alkanes (C6-C9);S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (X);0;;;;
n-Alkanens (C10+) ;;;>60°C;1;Ja;IBC;;;;;;;;x (Y);1;;;;
Alkylate;;;<60°C;2; ;MARPOL;;;;;;;;;;x;;6;
Alumina hydrate;;;;;;IMSBC;x;y;;A/B;2;;;;;;;;
alpha-Methylstyrene ;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
Ammonia aqueous (28% or less);S/P;2;NF;0;Ja;IBC;;;;;;;;x (Y);1;;;NF;
Ammonia / Anhydrous / Ammoniak;;;;; ;IGC;;;;;;1005;2.3;;;;x;;
Ammonia / Anhydrous / Ammoniak;;;;; ;IGC;;;;;;1005;02. Mrz;;;;x;;
Ammoniak Liquid 24,5% ;S/P;2;;;Ja;IBC;;;;;;;;x (Y);1;;;;
Ammonium Nitrate Fertilizer ;;;;; ;IMSBC;x;;;B;1;2067;5.1;;;;;;
Ammonium Nitrate with not more than 0,2% total;;;;; ;IMSBC;x;;;B;1;1942;5.1;;;;;;
Ammonium Nitrate Fertilizer ;;;;; ;IMSBC;x;;;B;1;2067;05. Jan;;;;;;
Ammonium Nitrate with not more than 0,2% total;;;;; ;IMSBC;x;;;B;1;1942;05. Jan;;;;;;
Ammonium Polyphosphate Solution (APP) ;P;0;>60°C;1;Nein;IBC;;;;;;;;x (Z);2;;;;
Ammonium Sulphate;;;;; ;;;;;;;;;;;;;;Keine Anmeldung, IMSBC Gruppe C
Ammonium nitrate solution (93% or less) ;S/P;2;NF;0;Nein;IBC;;;;;;;;x (Y);1;;;;
Ammonium thiosulphate solution (60% or less);S/P;2;NF;0;Nein;IBC;;;;;;;;x (Y);1;;;;
Ammonium thiosulphate solution (60% or less);S/P;2;NF;0;Nein;IBC;;;;;;;;x (Z);2;;;;
Aniline ;S/P;2;>60°C;1;Ja;IBC;;;;;;;;x (Y);1;;;;
Anthracene Oil;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (X);0;;;;
Anthracite / Coal / Kohle;;;;; ;IMSBC;x;y;;A/B;2;;;;;;;;Gruppe: B (und A)
ATRES / RAT / Atmospheric Residues / Residues (petroleum) atmospheric (APS Bottoms Resid A);;;>60°C;1;;MARPOL;;;;;;;;;;x;;;
AVGAS / Aviation Gasoline / Flugbenzin;;;;;;MARPOL;;;;;;;;;;x;;;
BALED RDF;;;;;;IMSBC;x ;y;;B;1;;;;;;;;
Base Oil / Lubricating oil / SN150/ SN500 / SN900 / VISOM 4 / Ultra S4 / Bright Stock / QHVI4 / QHVI8 / VHVI-4 = DISTILLATES (PETROLEUM) / HYDROTREATED HEAVY PARAFFINIC,;;;>60°C;1; ;MARPOL;;;;;;;;;;x;;;
Base Oil / Lubricating oil / SN150/ SN500 / SN900 / BS20 / NYTEX 4700 / T9 / T600 / T150 ANR / VISOM 4 / Ultra S4 / Bright Stock / QHVI4 / QHVI8 / VHVI-4 = DISTILLATES (PETROLEUM) / HYDROTREATED HEAVY PARAFFINIC,;;;>60°C;1; ;MARPOL;;;;;;;;;;x;;;
Benzene / Benzol;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;-11;
Biodiesel / FAME - Fatty acid methyl esters;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y) ;;;;;
Biodiesel / FAME - Fatty acid methyl esters;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y) ;1;;;;
Bitumen ;;;>60°C;1;;MARPOL;;;;;;;;;;x;;;
Blei in Blöcken / Lead Ingots;;;;;;;;;;;;;;;;;;; kein Gefahrgut! Aussage Herr Jnassen Rhenus Midgard Nordenham (tel. 21.07.2021)
Butan;;;;;;IGC;;;;;;1011;2.1;;;;x;;
Butene / Buthylen;;;;;;IGC;;;;;;1012;2.1;;;;x;;
Butan;;;;;;IGC;;;;;;1011;02. Jan;;;;x;;
Butene / Buthylen;;;;;;IGC;;;;;;1012;02. Jan;;;;x;;
Butyl acrylate (all isomers);S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
Calcined clay / Kalzinierter Ton;;;;; ;;;;;;;;;;;;;;Keine Anmeldung, IMSBC Gruppe C
C9 Petroleum Resin;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
@ -39,7 +40,7 @@ Calcium Ammonium Nitrate 27% N / CAN (in BULK);;;;; ;;;;;;;;;;;;;;Keine Anmeldun
Calcium Chloride Solution;P;0;>60°C;1;Nein;IBC;;;;;;;;x (Z);2;;;;
CARBON BLACK FEEDSTOCK / D8 / ANTHRACENE OIL;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (X);0;x;;;nach Sicherheitsdatenblatt fragen kann IBC oder Marpol sein
Carbon Black Oil Propylene Oxide;;;;;;MARPOL;;;;;;;;;;x;;;
Carbon Dioxide;;;;; ;IGC;;;;;;1013;2.2;;;;x;;
Carbon Dioxide;;;;; ;IGC;;;;;;1013;02. Feb;;;;x;;
Caromax 28 ;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (X);0;;;;
Caustic potash / Potassium hydroxide solution / Kalilauge ;S/P;2;NF;0;Ja;IBC;;;;;;;;x (Y);1;;;;
Caustic soda / Sodium hydroxide solution / Natronlauge;S/P;2;NF;0; Ja;IBC;;;;;;;;x (Y);1;;;;
@ -50,7 +51,7 @@ Coal Tar ,;S/P;2;>60
Coal Tar Pitch (Flüssig);S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (X);0;;;;
Coal Tar Pitch / Steinkohlenteerpech (FEST);;;;;;IMSBC;x;y;;B;1;;;;;;;;
Coconut oil ;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y);1;;;;
COKE BREEZE / Koksgrus;;;;; ;IMSBC;x;;;;;;;;;;;;"NICHT MHB + KEINE UN-Nummer! Mit UN-Nr. ""0000"" + IMO-class ""1.1"" eingeben + Vermerk: ""UN-no. + IMO-class not available"" (im Jgegis muss es mit ""MHB"" angemeldet werden) - GR. A"
COKE BREEZE / Koksgrus;;;;; ;IMSBC;x;;;A;0;;;;;;;;"NICHT MHB + KEINE UN-Nummer! Mit UN-Nr. ""0000"" + IMO-class ""1.1"" eingeben + Vermerk: ""UN-no. + IMO-class not available"" (im Jgegis muss es mit ""MHB"" angemeldet werden) - GR. A"
Used cooking oil (mit Triglycerides, C16-C18 and C18 unsaturated) ;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y);1;;;;
Used cooking oil (wenn Triglycerides nicht ausdrücklich ausgewiesen) ;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (X);0;;;;
Copper concentrates ;;;;; ;IMSBC;x;;;A;0;3077;9;;;;;;
@ -78,20 +79,21 @@ Ethyl acetate ;P;0;<60
Ethanol / Ethyl alcohol / Grain alcohol / Drinking alcohol;;;<60°C;2;Nein;IBC;;;;;;;;x (Z);2;;;;
Ethylene glycol / (Mono-)Ethylenglycol / MEG / Glycol;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Z);2;;;;
Ethyl tert-butyl ether / ETBE ;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
Ethylene;;;;; ;IGC;;;;;;1038;2.1;;;;X;;
ETHYLENE DICHLORIDE (ETD) ;S/P;2;<60°C;2;Ja;IBC;;;;;;;;x (Y) ;;;;;
Ethylene;;;;; ;IGC;;;;;;1038;02. Jan;;;;X;;
ETHYLENE DICHLORIDE (ETD oder EDC) ;S/P;2;<60°C;2;Ja;IBC;;;;;;1184;;x (Y) ;;;;;
Etibor / BORAX / PENTAHYDRATE CRUDE;;;;; ;;;;;;;;;;;;;;Keine Anmeldung
EXTRAIT / Vacuum gas oil;;;;;;MARPOL;;;;;;;;;;x;;;
Fatty acids, (C16+);P;0;<60°C;2;Nein;IBC;;;;;;;;x (Y) ;;;;;
FAME / Fatty acid methyl esters / Biodiesel ,;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y) ;;;;;
Fatty acids, (C16+);P;0;<60°C;2;Nein;IBC;;;;;;;;x (Y) ;1;;;;
FAME / Fatty acid methyl esters / Biodiesel ,;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y) ;1;;;;
Feed Phosphate / Monocalcium Phosphate;;;;; ;;;;;;;;;;;;;;Keine Anmeldung, IMSBC Gruppe C
Ferroalloys / Ferro Silico Mangan / Ferrolegierung (unter 20 %);;;;; ;;;;;;;;;;;;;;Keine Anmeldung, IMSBC Gruppe C
Ferrochrom;;;;;;;;;;;;;;;;;;;Keine Anmeldung, IMSBC Gruppe C
Ferrosilicochrom 40 / Ferrosilicon;;;;; ;IMSBC;x;;;B;1;1408;4.3;;;;;;
FERROUS METAL / BORINGS / SHAVINGS / TURNINGS / CUTTINGS;;;;; ;IMSBC;x;;;B;1;2793;4.2;;;;;;
Ferrosilicochrom 40 / Ferrosilicon;;;;; ;IMSBC;x;;;B;1;1408;04. Mrz;;;;;;
FERROUS METAL / BORINGS / SHAVINGS / TURNINGS / CUTTINGS;;;;; ;IMSBC;x;;;B;1;2793;04. Feb;;;;;;
FERTILIZER POTASH (PINK GRANULATED MURIATE OF POTASH);;;;;;IMSBC;x;;;;;;;;;;;;
Fish Meal treated with Antioxidant;;;;; ;IMSBC;x;;;B;1;2216;9;;;;;;wenn Ladehafen Bremen dann Gruppe C und nicht anzumelden
Fishoil;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y) ;;;;;
Fish Silage Protein Concentrate (containing 4% or less formic acid);P;0;NF;0;Nein;IBC;;;;;;;;x (Y) ;;;;;
Fishoil;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y) ;1;;;;
Fish Silage Protein Concentrate (containing 4% or less formic acid);P;0;NF;0;Nein;IBC;;;;;;;;x (Y) ;1;;;;
Fish protein concentrate (containing 4% or less formic acid);P;0;NF;0;Nein;IBC;;;;;;;;x (Z);2;;;;
FLUORSPAR / Flussspat;;;;; ;IMSBC;x;y;;B;1;;;;;;;;
Fly Ash;;;;; ;;;;;;;;;;;;;;Keine Anmeldung
@ -142,14 +144,14 @@ Liquid petroleum paraffin, fraction of C14-C17 <2% aromatics);P;0;>60
Lukoil / Crude Oil;;;;; ;MARPOL;;;;;;;;;;x;;;
Magnesium Chloride Solution;P;0;>60°C;1;Nein;IBC;;;;;;;;x (Z);2;;;;
Metal Sulphide Concentrates / Zink / Blei / Silber;;;;; ;IMSBC;x;y;;A/B;2;;;;;;;;
Methanol / Methyl Alcohol ;S/P;2;<60°C;2;Ja;IBC;;;;;;;;x (Y) ;;;;;
Methanol / Methyl Alcohol ;S/P;2;<60°C;2;Ja;IBC;;;;;;;;x (Y) ;1;;;;
Methyl Acrylate ;S/P;2;<60°C;2;Ja;IBC;;;;;;;;x (Y);1;;;;
Methyl Alcohol / Methanol ;S/P;2;<60°C;2;Ja;IBC;;;;;;;;x (Y) ;;;;;
Methyl Alcohol / Methanol ;S/P;2;<60°C;2;Ja;IBC;;;;;;;;x (Y) ;1;;;;
Methyl Isobutyl Ketone ;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Z);2;;;;
Methylendiphenylisocyanate / MDI / Polymethylene polyphenyl isocyanate ;S/P;2;>60°C;1;Ja;IBC;;;;;;;;x (Y) ;;;;;
Methyl Methacrylate Monomer / MMM ;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y) ;;;;;
Methylendiphenylisocyanate / MDI / Polymethylene polyphenyl isocyanate ;S/P;2;>60°C;1;Ja;IBC;;;;;;;;x (Y) ;1;;;;
Methyl Methacrylate Monomer / MMM ;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y) ;1;;;;
Methyl Tert-Butyl Ether / MTBE ;P;0;<60°C;2;Nein;IBC;;;;;;;;x (Z);2;;;;
Mixed Fatty acid / MFA;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y) ;;;;;
Mixed Fatty acid / MFA;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y) ;1;;;;
Mixed Xylene ;P;0;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
Molasses;;;NF;0; ;IBC;;;;;;;;x (OS);3;;;;Nicht anmeldepflichtig - Ausnahme: BREMEN (lt Auskunft von Herrn Kraft 09.01.2018)//FÜR BREMEN ANMELDEN ÜBER J GEGIS - an DBH - ohne Visit ID
Monoammonium Phosphate / MAP;;;;; ;;;;;;;;;;;;;;Keine Anmeldung
@ -180,13 +182,14 @@ Noxious liquid, NF(5) n.o.s.(Solvesso 100, contains Alkyl (C3-C4) benzenes) ;
Noxious liquid, NF, (7) n.o.s. (Exxsol D80 , contains iso-and cycloalkanes(C12+));P;0;>60°C;1;Ja;IBC;;;;;;;;x (Y);1;;;;
Noxious liquid, NF, (7) n.o.s. ((EXXSOL D60 und auch Nessol D60, contains iso-and cycloalkanes (C10-C11));P;0;>60°C;1;Ja;IBC;;;;;;;;x (Y);1;;;;
Noxious liquid, F, (8) n.o.s. (NESSOL D40 contains Iso- and cycloalkanes (C10-C11)) ;P;0;<60°C;2;ja;IBC;;;;;;;;x (Y);1;;;;
Noxious liquid, F, (11?) n.o.s. (ETHYLOL 95, contains Ethyl alcohol)) ;P;0;<60°C;2;Nein;IBC;;;;;;;;x (Z);2;;;;
NPK Fertilizer / Ammonium Nitrate Based Fertilizer (Non Hazardous);;;;; ;;;;;;;;;;;;;;Keine Anmeldung
Nynas VR5000 / Bitumen;;;>60°C;1;;MARPOL;;;;;;;;;;x;;;
NYTRO TAURUS / Insulating Oil;;;;;;MARPOL;;;;;;;;;;x;;;
Octene;P;0;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
Odourless Kerosene D70 ;;;;;;MARPOL;;;;;;;;;;x;;;
Olivines / Mineralgemisch gehört Mineralklasse der „Silikate und Germanate“ ;;;;;;;;;;;;;;;;;;;Keine Anmeldung
Olive Stones (crushed) / Seed Cake / Oil Cake;;;;; ;IMSBC;x;;;B;1;1386;4.2;;;;;;
Olive Stones (crushed) / Seed Cake / Oil Cake;;;;; ;IMSBC;x;;;B;1;1386;04. Feb;;;;;;
ORTHO-XYLENE ;P;0;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
Palm fatty acid distillate / PFAD;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y);1;;;;
Palmkernexpellers / pulverisierte Kernschalen;;;;;;;;;;;;;;;;;;;Keine Anmeldung lt. J.Müller Brake - siehe aber auch SEED CAKE
@ -217,15 +220,15 @@ Polyolefin (molecular weight 300+) ;P;0;>60
Potash / Pottasche;;;;; ;;;;;;;;;;;;;;Keine Anmeldung
Potassium Hydroxide Solution / Caustic Potash / Kaliumhydroxidlösung;S/P;2;NF;0;Ja;IBC;;;;;;;;x (Y);1;;;;
Propylbenzene / all isomers;P;0;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
Propylene;;;;; ;IGC;;;;;;1077;2.2;;;;x;;
Propylene Dichloride / 1,2-DICHLOROPROPANE;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y) ;;;;;
Propylene;;;;; ;IGC;;;;;;1077;02. Feb;;;;x;;
Propylene Dichloride / 1,2-DICHLOROPROPANE;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y) ;1;;;;
Propylene Glycol Monoalkyl Ether / DOWANOL PM;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Z);2;;;;
Propylene Oxide; ;; ;; ;IGC;;;;;;1280;3;;;;x;;
Propylene Oxide;S/P;2;<60°C;2;ja;IBC;;;;;;;; ;;;;;
Propylene Oxide;S/P;2;<60°C;2;Ja;IBC;;;;;;;;x (Y);1;;;;
Propylene Tetramer ;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (X);0;;;;
Propylene Trimer ;P;0;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
Pyrolysis Fuel Oil;;;;; ;IBC;;;;;;;;?;;?;;;
Pyrolysis Gasoline containing benzene / Pygas /Aromatic hydrocarbons / C6-8 / Naphtha-Raffinate Pyrolyzate-derived ;S/P;2;<60°C;2;Nein;IBC;;;;;;;; x (Y) ;;;;;
Pyrolysis Gasoline containing benzene / Pygas /Aromatic hydrocarbons / C6-8 / Naphtha-Raffinate Pyrolyzate-derived ;S/P;2;<60°C;2;Nein;IBC;;;;;;;; x (Y) ;1;;;;
Pyrite;;;;;;;;;;;;;;;;;;;"Achtung! Kann ""IMSBC: Gruppe C"" (also nicht anmeldepflichig sein) oder auch ""Gruppe: A"" bzw. ""Gruppe: A/B"" (somit Anmeldepflichtig)- beim Kunden nachfragen und ""Shippers declaration for solid bulk cargos"" oder es nennt sich auch ""Cargo information for solid bulk cargos"" anfordern"
Quicklime / Kalk ungelöscht / Lime / Burnt Lime / Un-slaked Lime / Building Lime / Calcia / Fat Lime / Chemical Lime / Fluxing Lime / Hard Burnt Lime / Soft Burnt Lime / Pebble Lime / Calcium Oxide / Calcium Monoxide / Calcined Limestone / Calcium oxide / CaO;;;;;;IMSBC;x;Y;;B;1;;;;;;;;
Rapeseed oil / Rapsöl;P;0;>60°C;1;Nein;IBC;;;;;;;;x (Y);1;;;;
@ -237,8 +240,8 @@ RDF pellets / Refuse Derived Fuel;;;;; ;;;;;;;;;;;;;;Keine Anmeldung
Resin Oil / Distilled ;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
RME 0,4MG/11 / FAME;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y);1;;;;
Sawn Timber / Schnittholz / Sägeholz;;;;; ;IMSBC;x;;;;;;;;;;;;nur wenn als Bulk (also keine Verpackung jeglicher Art (Drahtseile, Kunststoffbänder) und unter Deck
SEED Cake mit einem Ölgehalt von höchstens 1,5% und einem Feuchtigkeitsgehalt von höchstens 11% ///with not more than 1.5% oil and not more than 11% moisture.;;;;;;IMSBC;x;;;B;1;2217;4.2;;;;;;
SEED Cake containing vegetable oil a) durch mechanisches Pressen gewonnene Ölsaatenrückstände, die mehr als 10% Öl oder mehr als 20% Öl und Feuchtigkeit zusammen enthalten / (a) mechanically expelled seeds, containing more than 10% of oil or more than 20% of oil and moisture combined.);;;;;;IMSBC;x;;;B;1;1386;4.2;;;;;;
SEED Cake mit einem Ölgehalt von höchstens 1,5% und einem Feuchtigkeitsgehalt von höchstens 11% ///with not more than 1.5% oil and not more than 11% moisture.;;;;;;IMSBC;x;;;B;1;2217;04. Feb;;;;;;
SEED Cake containing vegetable oil a) durch mechanisches Pressen gewonnene Ölsaatenrückstände, die mehr als 10% Öl oder mehr als 20% Öl und Feuchtigkeit zusammen enthalten / (a) mechanically expelled seeds, containing more than 10% of oil or more than 20% of oil and moisture combined.);;;;;;IMSBC;x;;;B;1;1386;04. Feb;;;;;;
Shale Oil;;;;; ;MARPOL;;;;;;;;;;x;;;
Slack Wax / Petroleum / Hydrocarbon Wax;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (X);0;;;;
Slop Water;;;;; ;;;;;;;;;;;;;;Keine Anmeldung lt. Johann/16.12.12
@ -246,14 +249,14 @@ Slops;;;;; ;;;;;;;;;;;;;;
Slurry / Residues / Petroleum;;;;; ;MARPOL;;;;;;;;;;x ;;;
Small Arms = Waffen zur Schiffsausrüstung gehörig;;;;; ;;;;;;;;;;;;;;Keine Anmeldung lt. Aussage von Fr. Kauschmann/16.05.2013 (09:50 Uhr)
Solvent ;;;;;;;;;;;;;;;;;;;Sicherheitsdatenblatt anfordern!!!
Sodium hydroxide solution / Caustic soda / Natronlauge;S/P;2;NF;0;Ja;IBC;;;;;;;;x (Y);;;;;
Sodium hydroxide solution / Caustic soda / Natronlauge;S/P;2;NF;0;Ja;IBC;;;;;;;;x (Y);1;;;;
Sodium Sulphate in Bulk;;;;; ;;;;;;;;;;;;;;Keine Anmeldung lt. Aussage von Herrn Illing Gefahrgutauskunfststelle Hamburg/14.02.14-10.25 Uhr
Soyabean meal / SBM / Sojabohnenmehl;;;;; ;IMSBC;x;y;;;;;;;;;;;"Kann Cat. A, B oder C sein (abhängig von der Zusammensetzung),
wenn keine genaue Angabe => Anfragen, ob anmledepflichtig oder nicht,
Wenn Port of Loading = Brake oder Hamburg => Cat. C und damit nicht anmeldepflichtig"
Soyabean Oil ,;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y);1;;;;
Soja protein concentrat / SPC;;;;;;;;;;;;;;;;;;;Keine Anmeldung
Steel Turnings;;;;; ;IMSBC;x;;;B;1;2793;4.2;;;;;;
Steel Turnings;;;;; ;IMSBC;x;;;B;1;2793;04. Feb;;;;;;
Styrene Monomer ,;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Y);1;;;;
Sulphur (molten) ;S;1;>60°C;1;Nein;IMSBC; ;;;;;;;x (Z);2;;;;
Sulphuric Acid;S/P;2;NF;0;Ja;IBC;;;;;;;;x (Y);1;;;;
@ -273,7 +276,7 @@ Nynas Naphthenic / Tyre Oils;;;;; ;MARPOL;;;;;;;;;;x;;;
Ultra-Low Sulphur Fuel Oil / ULSFO;;;;;;MARPOL;;;;;;;;;;x;;;
Urea Grain in bulk ;;;;; ;;;;;;;;;;;;;;Keine Anmeldung, IMSBC Gruppe C
Urea Ammonium Nitrate solution / UAN (containing less than 1% free ammonia) ;S/P;2;NF;0;Nein;IBC;;;;;;;;x (Y);1;;;;
Urea solution ;S/P;2;<60°C;2;Nein;IBC;;;;;;;;x (Z);2;;;;
Urea solution ;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Z);2;;;;
Urea Grain in bulk;;;;;;;;;;;;;;;;;;;Keine Anmeldung, IMSBC Gruppe C
VGO / Vakuum Gas Öl / Schweres Vakuumgasöl / HVGO;;;<60°C;2; ;MARPOL;;;;;;3082;9;;;x;;;
Vegetable acid oils;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (Y) ;;;;;
@ -283,7 +286,7 @@ Vinyl Acetate monomer;S/P;2;<60
VISTAR HS / Distillates Petroleum;;;;;;MARPOL;;;;;;;;;;x;;;
Wash Oil / Creosote oil / METHYLNAPHTHALENE acenaphthene fraction;S/P;2;>60°C;1;Nein;IBC;;;;;;;;x (X);0;;;;
Washed Waelz Oxide / Zink / zinkhaltiger Staub;;;;;;IMSBC;x;;;A;0;;;;;;;;lt. Rhenus Midgard/Hr. Janssen
Wilfarin PA1698 RSPO (siehe Fatty acids, (C16+) );P;0;>60°C;1;Nein;IBC;;;;;;;;x (X);0;;;;
Wilfarin PA1698 RSPO (siehe Fatty acids, (C16+) );P;0;>60°C;1;Nein;;;;;;;;;;;;;;
WOOD PELLETS ;;;;; ;IMSBC;x;y;;B;1;;;;;;;;
Wood pulp;;;;;;;;;;;;;;;;;;;nicht anmelden = Aussage J.Müller, kein DG
Wood pulp pellets ;;;;; ;IMSBC;x;y;;B;1;;;;;;;;

1 Beschreibung Gefahr HAZARD_ENUM FP FP_ENUM 15.19? Typ IMSBC MHB IMSBC_MHB Group IMSBC_HAZ UN-Nr. IMO-Cl. IBC POLLUTION_CATEGORY_ENUM MARPOL IGC FP_IBC Bemerkung
8 Alkanes (C6-C9) S/P 2 <60°C 2 Nein IBC x (X) 0
9 n-Alkanens (C10+) >60°C 1 Ja IBC x (Y) 1
10 Alkylate <60°C 2 MARPOL x 6
11 Alumina hydrate IMSBC x y A/B 2
12 alpha-Methylstyrene S/P 2 <60°C 2 Nein IBC x (Y) 1
13 Ammonia aqueous (28% or less) S/P 2 NF 0 Ja IBC x (Y) 1 NF
14 Ammonia / Anhydrous / Ammoniak IGC 1005 2.3 02. Mrz x
15 Ammoniak Liquid 24,5% S/P 2 Ja IBC x (Y) 1
16 Ammonium Nitrate Fertilizer IMSBC x B 1 2067 5.1 05. Jan
17 Ammonium Nitrate with not more than 0,2% total IMSBC x B 1 1942 5.1 05. Jan
18 Ammonium Polyphosphate Solution (APP) P 0 >60°C 1 Nein IBC x (Z) 2
19 Ammonium Sulphate Keine Anmeldung, IMSBC Gruppe C
20 Ammonium nitrate solution (93% or less) S/P 2 NF 0 Nein IBC x (Y) 1
21 Ammonium thiosulphate solution (60% or less) S/P 2 NF 0 Nein IBC x (Y) x (Z) 1 2
22 Aniline S/P 2 >60°C 1 Ja IBC x (Y) 1
23 Anthracene Oil S/P 2 >60°C 1 Nein IBC x (X) 0
24 Anthracite / Coal / Kohle IMSBC x y A/B 2 Gruppe: B (und A)
25 ATRES / RAT / Atmospheric Residues / Residues (petroleum) atmospheric (APS Bottoms Resid A) >60°C 1 MARPOL x
26 AVGAS / Aviation Gasoline / Flugbenzin MARPOL x
27 BALED RDF IMSBC x y B 1
28 Base Oil / Lubricating oil / SN150/ SN500 / SN900 / VISOM 4 / Ultra S4 / Bright Stock / QHVI4 / QHVI8 / VHVI-4 = DISTILLATES (PETROLEUM) / HYDROTREATED HEAVY PARAFFINIC, Base Oil / Lubricating oil / SN150/ SN500 / SN900 / BS20 / NYTEX 4700 / T9 / T600 / T150 ANR / VISOM 4 / Ultra S4 / Bright Stock / QHVI4 / QHVI8 / VHVI-4 = DISTILLATES (PETROLEUM) / HYDROTREATED HEAVY PARAFFINIC, >60°C 1 MARPOL x
29 Benzene / Benzol S/P 2 <60°C 2 Nein IBC x (Y) 1 -11
30 Biodiesel / FAME - Fatty acid methyl esters S/P 2 >60°C 1 Nein IBC x (Y) 1
31 Bitumen >60°C 1 MARPOL x
32 Blei in Blöcken / Lead Ingots kein Gefahrgut! Aussage Herr Jnassen Rhenus Midgard Nordenham (tel. 21.07.2021)
33 Butan IGC 1011 2.1 02. Jan x
34 Butene / Buthylen IGC 1012 2.1 02. Jan x
35 Butyl acrylate (all isomers) S/P 2 <60°C 2 Nein IBC x (Y) 1
36 Calcined clay / Kalzinierter Ton Keine Anmeldung, IMSBC Gruppe C
37 C9 Petroleum Resin S/P 2 <60°C 2 Nein IBC x (Y) 1
40 Calcium Chloride Solution P 0 >60°C 1 Nein IBC x (Z) 2
41 CARBON BLACK FEEDSTOCK / D8 / ANTHRACENE OIL S/P 2 >60°C 1 Nein IBC x (X) 0 x nach Sicherheitsdatenblatt fragen kann IBC oder Marpol sein
42 Carbon Black Oil Propylene Oxide MARPOL x
43 Carbon Dioxide IGC 1013 2.2 02. Feb x
44 Caromax 28 S/P 2 >60°C 1 Nein IBC x (X) 0
45 Caustic potash / Potassium hydroxide solution / Kalilauge S/P 2 NF 0 Ja IBC x (Y) 1
46 Caustic soda / Sodium hydroxide solution / Natronlauge S/P 2 NF 0 Ja IBC x (Y) 1
51 Coal Tar Pitch (Flüssig) S/P 2 >60°C 1 Nein IBC x (X) 0
52 Coal Tar Pitch / Steinkohlenteerpech (FEST) IMSBC x y B 1
53 Coconut oil S/P 2 >60°C 1 Nein IBC x (Y) 1
54 COKE BREEZE / Koksgrus IMSBC x A 0 NICHT MHB + KEINE UN-Nummer! Mit UN-Nr. "0000" + IMO-class "1.1" eingeben + Vermerk: "UN-no. + IMO-class not available" (im Jgegis muss es mit "MHB" angemeldet werden) - GR. A
55 Used cooking oil (mit Triglycerides, C16-C18 and C18 unsaturated) S/P 2 >60°C 1 Nein IBC x (Y) 1
56 Used cooking oil (wenn Triglycerides nicht ausdrücklich ausgewiesen) S/P 2 >60°C 1 Nein IBC x (X) 0
57 Copper concentrates IMSBC x A 0 3077 9
79 Ethylene glycol / (Mono-)Ethylenglycol / MEG / Glycol S/P 2 >60°C 1 Nein IBC x (Z) 2
80 Ethyl tert-butyl ether / ETBE S/P 2 <60°C 2 Nein IBC x (Y) 1
81 Ethylene IGC 1038 2.1 02. Jan X
82 ETHYLENE DICHLORIDE (ETD) ETHYLENE DICHLORIDE (ETD oder EDC) S/P 2 <60°C 2 Ja IBC 1184 x (Y)
83 Etibor / BORAX / PENTAHYDRATE CRUDE Keine Anmeldung
84 EXTRAIT / Vacuum gas oil MARPOL x
85 Fatty acids, (C16+) P 0 <60°C 2 Nein IBC x (Y) 1
86 FAME / Fatty acid methyl esters / Biodiesel , S/P 2 >60°C 1 Nein IBC x (Y) 1
87 Feed Phosphate / Monocalcium Phosphate Keine Anmeldung, IMSBC Gruppe C
88 Ferroalloys / Ferro Silico Mangan / Ferrolegierung (unter 20 %) Keine Anmeldung, IMSBC Gruppe C
89 Ferrochrom Keine Anmeldung, IMSBC Gruppe C
90 Ferrosilicochrom 40 / Ferrosilicon IMSBC x B 1 1408 4.3 04. Mrz
91 FERROUS METAL / BORINGS / SHAVINGS / TURNINGS / CUTTINGS IMSBC x B 1 2793 4.2 04. Feb
92 Fish Meal treated with Antioxidant FERTILIZER POTASH (PINK GRANULATED MURIATE OF POTASH) IMSBC x B 1 2216 9 wenn Ladehafen Bremen dann Gruppe C und nicht anzumelden
93 Fish Meal treated with Antioxidant IMSBC x B 1 2216 9 wenn Ladehafen Bremen dann Gruppe C und nicht anzumelden
94 Fishoil S/P 2 >60°C 1 Nein IBC x (Y) 1
95 Fish Silage Protein Concentrate (containing 4% or less formic acid) P 0 NF 0 Nein IBC x (Y) 1
96 Fish protein concentrate (containing 4% or less formic acid) P 0 NF 0 Nein IBC x (Z) 2
97 FLUORSPAR / Flussspat IMSBC x y B 1
98 Fly Ash Keine Anmeldung
99 Formaldehyde solutions / Formalin S/P 2 >60°C 1 Ja IBC x (Y) 1
144 Magnesium Chloride Solution P 0 >60°C 1 Nein IBC x (Z) 2
145 Metal Sulphide Concentrates / Zink / Blei / Silber IMSBC x y A/B 2
146 Methanol / Methyl Alcohol S/P 2 <60°C 2 Ja IBC x (Y) 1
147 Methyl Acrylate S/P 2 <60°C 2 Ja IBC x (Y) 1
148 Methyl Alcohol / Methanol S/P 2 <60°C 2 Ja IBC x (Y) 1
149 Methyl Isobutyl Ketone S/P 2 <60°C 2 Nein IBC x (Z) 2
150 Methylendiphenylisocyanate / MDI / Polymethylene polyphenyl isocyanate S/P 2 >60°C 1 Ja IBC x (Y) 1
151 Methyl Methacrylate Monomer / MMM S/P 2 <60°C 2 Nein IBC x (Y) 1
152 Methyl Tert-Butyl Ether / MTBE P 0 <60°C 2 Nein IBC x (Z) 2
153 Mixed Fatty acid / MFA S/P 2 >60°C 1 Nein IBC x (Y) 1
154 Mixed Xylene P 0 <60°C 2 Nein IBC x (Y) 1
155 Molasses NF 0 IBC x (OS) 3 Nicht anmeldepflichtig - Ausnahme: BREMEN (lt Auskunft von Herrn Kraft 09.01.2018)//FÜR BREMEN ANMELDEN ÜBER J GEGIS - an DBH - ohne Visit ID
156 Monoammonium Phosphate / MAP Keine Anmeldung
157 Monocalcium Phosphate / MCP / Futtermittel IMSBC x y A/B 2 Verpackt (IMDG) nicht anmeldepflichtig
182 Noxious liquid, NF, (7) n.o.s. ((EXXSOL D60 und auch Nessol D60, contains iso-and cycloalkanes (C10-C11)) P 0 >60°C 1 Ja IBC x (Y) 1
183 Noxious liquid, F, (8) n.o.s. (NESSOL D40 contains Iso- and cycloalkanes (C10-C11)) P 0 <60°C 2 ja IBC x (Y) 1
184 NPK Fertilizer / Ammonium Nitrate Based Fertilizer (Non Hazardous) Noxious liquid, F, (11?) n.o.s. (ETHYLOL 95, contains Ethyl alcohol)) P 0 <60°C 2 Nein IBC x (Z) 2 Keine Anmeldung
185 NPK Fertilizer / Ammonium Nitrate Based Fertilizer (Non Hazardous) Keine Anmeldung
186 Nynas VR5000 / Bitumen >60°C 1 MARPOL x
187 NYTRO TAURUS / Insulating Oil MARPOL x
188 Octene P 0 <60°C 2 Nein IBC x (Y) 1
189 Odourless Kerosene D70 MARPOL x
190 Olivines / Mineralgemisch gehört Mineralklasse der „Silikate und Germanate“ Keine Anmeldung
191 Olive Stones (crushed) / Seed Cake / Oil Cake IMSBC x B 1 1386 4.2 04. Feb
192 ORTHO-XYLENE P 0 <60°C 2 Nein IBC x (Y) 1
193 Palm fatty acid distillate / PFAD S/P 2 >60°C 1 Nein IBC x (Y) 1
194 Palmkernexpellers / pulverisierte Kernschalen Keine Anmeldung lt. J.Müller Brake - siehe aber auch SEED CAKE
195 PALM KERNEL OIL / CPKO / Crude Palm Kernel Oil S/P 2 >60°C 1 Nein IBC x (Y) 1
220 Potassium Hydroxide Solution / Caustic Potash / Kaliumhydroxidlösung S/P 2 NF 0 Ja IBC x (Y) 1
221 Propylbenzene / all isomers P 0 <60°C 2 Nein IBC x (Y) 1
222 Propylene IGC 1077 2.2 02. Feb x
223 Propylene Dichloride / 1,2-DICHLOROPROPANE S/P 2 <60°C 2 Nein IBC x (Y) 1
224 Propylene Glycol Monoalkyl Ether / DOWANOL PM S/P 2 <60°C 2 Nein IBC x (Z) 2
225 Propylene Oxide IGC 1280 3 x
226 Propylene Oxide S/P 2 <60°C 2 ja Ja IBC x (Y) 1
227 Propylene Tetramer S/P 2 <60°C 2 Nein IBC x (X) 0
228 Propylene Trimer P 0 <60°C 2 Nein IBC x (Y) 1
229 Pyrolysis Fuel Oil IBC ? ?
230 Pyrolysis Gasoline containing benzene / Pygas /Aromatic hydrocarbons / C6-8 / Naphtha-Raffinate Pyrolyzate-derived S/P 2 <60°C 2 Nein IBC x (Y) 1
231 Pyrite Achtung! Kann "IMSBC: Gruppe C" (also nicht anmeldepflichig sein) oder auch "Gruppe: A" bzw. "Gruppe: A/B" (somit Anmeldepflichtig)- beim Kunden nachfragen und "Shippers declaration for solid bulk cargos" oder es nennt sich auch "Cargo information for solid bulk cargos" anfordern
232 Quicklime / Kalk ungelöscht / Lime / Burnt Lime / Un-slaked Lime / Building Lime / Calcia / Fat Lime / Chemical Lime / Fluxing Lime / Hard Burnt Lime / Soft Burnt Lime / Pebble Lime / Calcium Oxide / Calcium Monoxide / Calcined Limestone / Calcium oxide / CaO IMSBC x Y B 1
233 Rapeseed oil / Rapsöl P 0 >60°C 1 Nein IBC x (Y) 1
234 Rape seed oil fatty acid methyl esters S/P 2 >60°C 1 Nein IBC x (Y) 1
240 RME 0,4MG/11 / FAME S/P 2 >60°C 1 Nein IBC x (Y) 1
241 Sawn Timber / Schnittholz / Sägeholz IMSBC x nur wenn als Bulk (also keine Verpackung jeglicher Art (Drahtseile, Kunststoffbänder) und unter Deck
242 SEED Cake mit einem Ölgehalt von höchstens 1,5% und einem Feuchtigkeitsgehalt von höchstens 11% ///with not more than 1.5% oil and not more than 11% moisture. IMSBC x B 1 2217 4.2 04. Feb
243 SEED Cake containing vegetable oil a) durch mechanisches Pressen gewonnene Ölsaatenrückstände, die mehr als 10% Öl oder mehr als 20% Öl und Feuchtigkeit zusammen enthalten / (a) mechanically expelled seeds, containing more than 10% of oil or more than 20% of oil and moisture combined.) IMSBC x B 1 1386 4.2 04. Feb
244 Shale Oil MARPOL x
245 Slack Wax / Petroleum / Hydrocarbon Wax S/P 2 >60°C 1 Nein IBC x (X) 0
246 Slop Water Keine Anmeldung lt. Johann/16.12.12
247 Slops
249 Small Arms = Waffen zur Schiffsausrüstung gehörig Keine Anmeldung lt. Aussage von Fr. Kauschmann/16.05.2013 (09:50 Uhr)
250 Solvent Sicherheitsdatenblatt anfordern!!!
251 Sodium hydroxide solution / Caustic soda / Natronlauge S/P 2 NF 0 Ja IBC x (Y) 1
252 Sodium Sulphate in Bulk Keine Anmeldung lt. Aussage von Herrn Illing Gefahrgutauskunfststelle Hamburg/14.02.14-10.25 Uhr
253 Soyabean meal / SBM / Sojabohnenmehl IMSBC x y Kann Cat. A, B oder C sein (abhängig von der Zusammensetzung), wenn keine genaue Angabe => Anfragen, ob anmledepflichtig oder nicht, Wenn Port of Loading = Brake oder Hamburg => Cat. C und damit nicht anmeldepflichtig
254 Soyabean Oil , S/P 2 >60°C 1 Nein IBC x (Y) 1
255 Soja protein concentrat / SPC Keine Anmeldung
256 Steel Turnings IMSBC x B 1 2793 4.2 04. Feb
257 Styrene Monomer , S/P 2 <60°C 2 Nein IBC x (Y) 1
258 Sulphur (molten) S 1 >60°C 1 Nein IMSBC x (Z) 2
259 Sulphuric Acid S/P 2 NF 0 Ja IBC x (Y) 1
260 Sunflower Husk Pellets in bulk Keine Anmeldung, Gruppe C - tel Aussage Hr. Meiners (J.Müller)
261 Sunflower Seed Oil S/P 2 >60°C 1 Nein IBC x (Y)
262 Tall oil fatty acid / TOFA (resin acids less than 20%) S/P 2 >60°C 1 Nein IBC x (Y) 1
276 Urea solution S/P 2 <60°C >60°C 2 1 Nein IBC x (Z) 2
277 Urea Grain in bulk Keine Anmeldung, IMSBC Gruppe C
278 VGO / Vakuum Gas Öl / Schweres Vakuumgasöl / HVGO <60°C 2 MARPOL 3082 9 x
279 Vegetable acid oils S/P 2 >60°C 1 Nein IBC x (Y)
280 Versene 100 / ETHYLENEDIAMINETETRAACETIC ACID NA4-SALT S/P 2 <60°C 2 Nein IBC x (Y) 1
281 Versenex 80 / Diethylenetriaminepentaacetic acid / pentasodium salt solution P 0 >60°C 1 Nein IBC x (Z) 2
282 Vinyl Acetate monomer S/P 2 <60°C 2 Nein IBC x (Y)
286 Wilfarin PA1698 RSPO (siehe Fatty acids, (C16+) ) P 0 >60°C 1 Nein IBC x (X) 0
287 WOOD PELLETS IMSBC x y B 1
288 Wood pulp nicht anmelden = Aussage J.Müller, kein DG
289 Wood pulp pellets IMSBC x y B 1
290 WOODCHIPS IMSBC x y B 1
291 Wooden poles / Holzstämme IMSBC x y B 1 NUR UNTER DECK (in Luken) anzumeldem - DECKSLADUNG NICHT! (außer für Baltic Lloyd, Rostock - ALLES anmelden!) lt. Herrn Ronneberger
292 Xylenes / Ortho-Xylene / Para Xylene P 0 <60°C 2 Nein IBC x (Y) 1

Binary file not shown.

Binary file not shown.

View File

@ -5,6 +5,7 @@ ____
Wird verwendet in Dangerous Goods, wenn der Button NewDGItem gedrückt Wird.
1) bei geliefertem Excel unnötige Spalten entfernen
1.5) Ggf. fehlende Werte in den XY_ENUM Spalten ergänzen
2) als CSV speichern
3) beim Import in DB Browser für SQLite ("Import CSV into Table") darauf achten, dass UTF-8 ausgewählt ist
4) Im DB Browser die relevanten Spalten von TEXT auf NUMERIC stellen