smaller bugfixes for comments

This commit is contained in:
Daniel Schick 2025-03-05 10:52:36 +01:00
parent 6d0a258236
commit bcee0383b7
12 changed files with 58 additions and 28 deletions

View File

@ -1,20 +1,8 @@
// Copyright (c) 2017 Informatibüro Daniel Schick
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
using bsmd.database;
using System.Windows.Controls;
using System.Windows.Input;
namespace ENI2
{
@ -62,7 +50,7 @@ namespace ENI2
{
if((this.MessageCoreSelected != null) && (aMessageCore != null))
{
this.MessageCoreSelected(aMessageCore);
this.MessageCoreSelected(aMessageCore, DBManager.Instance.GetReportingPartyDict()[App.UserId.Value].ShipcallDisplayMode);
}
}

View File

@ -607,7 +607,7 @@ namespace ENI2.Controls
MaerskData md = grid.SelectedItem as MaerskData;
if(md.MessageCore != null) {
Util.UIHelper.SetBusyState();
this.MessageCoreSelected?.Invoke(md.MessageCore);
this.MessageCoreSelected?.Invoke(md.MessageCore, DBManager.Instance.GetReportingPartyDict()[App.UserId.Value].ShipcallDisplayMode);
}
}
}

View File

@ -40,7 +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); };
this.dataGridBKRD.CellEditEnding += (obj, ev) => { this.SublistElementChanged(Message.NotificationClass.BKRD); };
startupComplete = true;
}

View File

@ -36,8 +36,8 @@
<MinimumRequiredVersion>5.4.0.0</MinimumRequiredVersion>
<CreateWebPageOnPublish>true</CreateWebPageOnPublish>
<WebPage>publish.html</WebPage>
<ApplicationRevision>3</ApplicationRevision>
<ApplicationVersion>7.2.7.3</ApplicationVersion>
<ApplicationRevision>4</ApplicationRevision>
<ApplicationVersion>7.2.7.4</ApplicationVersion>
<UseApplicationTrust>false</UseApplicationTrust>
<CreateDesktopShortcut>true</CreateDesktopShortcut>
<PublishWizardCompleted>true</PublishWizardCompleted>

View File

@ -135,7 +135,7 @@ namespace ENI2
this._dbWatchDog.Register(aMessageCore);
drc.HighlightReset += Drc_HighlightReset;
drc.OpenNewCoreRequested += (core) => this.AnmeldungenControl_MessageCoreSelected(core);
drc.OpenNewCoreRequested += (core) => this.AnmeldungenControl_MessageCoreSelected(core, DBManager.Instance.GetReportingPartyDict()[App.UserId.Value].ShipcallDisplayMode);
drc.ReloadCoreRequested += Drc_ReloadCoreRequested;
}
@ -472,7 +472,7 @@ namespace ENI2
if (((ShowIdDialog)sid).OpenCore)
{
Dispatcher.BeginInvoke((Action)(() => {
this.AnmeldungenControl_MessageCoreSelected(closedDialog.Core); // in einem neuen Reiter öffnen
this.AnmeldungenControl_MessageCoreSelected(closedDialog.Core, DBManager.Instance.GetReportingPartyDict()[App.UserId.Value].ShipcallDisplayMode); // in einem neuen Reiter öffnen
}));
}
@ -540,7 +540,7 @@ namespace ENI2
// Meldeklassen für neuen Anlauf erzeugen:
bsmd.database.Util.CreateMessagesForCore(newCore, null, userEntity);
this.AnmeldungenControl_MessageCoreSelected(newCore); // in einem neuen Reiter öffnen
this.AnmeldungenControl_MessageCoreSelected(newCore, DBManager.Instance.GetReportingPartyDict()[App.UserId.Value].ShipcallDisplayMode); // in einem neuen Reiter öffnen
// watchdog registrieren, damit die "grüne" Markierung erscheint, sobald die Anmeldung durch den Excel-Prozess gelaufen ist.
this._dbWatchDog.Register(newCore);
@ -612,7 +612,7 @@ namespace ENI2
showIdDialog.Closed += (sid, showIdArgs) =>
{
if (((ShowIdDialog)sid).OpenCore)
this.AnmeldungenControl_MessageCoreSelected(changedCore);
this.AnmeldungenControl_MessageCoreSelected(changedCore, DBManager.Instance.GetReportingPartyDict()[App.UserId.Value].ShipcallDisplayMode);
};
showIdDialog.Show();
showIdDialog.Activate();

View File

@ -4008,6 +4008,15 @@ namespace ENI2.Properties {
}
}
/// <summary>
/// Looks up a localized string similar to MDH simplification available.
/// </summary>
public static string textMDHSimplification {
get {
return ResourceManager.GetString("textMDHSimplification", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Was a medical practitioner consulted?.
/// </summary>
@ -5205,6 +5214,15 @@ namespace ENI2.Properties {
}
}
/// <summary>
/// Looks up a localized string similar to SEC simplification available.
/// </summary>
public static string textSECSimplification {
get {
return ResourceManager.GetString("textSECSimplification", resourceCulture);
}
}
/// <summary>
/// Looks up a localized string similar to Security.
/// </summary>

View File

@ -2227,4 +2227,10 @@
<data name="textRepeatNewPassword" xml:space="preserve">
<value>Repeat new password</value>
</data>
<data name="textMDHSimplification" xml:space="preserve">
<value>MDH simplification available</value>
</data>
<data name="textSECSimplification" xml:space="preserve">
<value>SEC simplification available</value>
</data>
</root>

View File

@ -304,7 +304,7 @@
</DatePicker>
<TextBox Grid.Row="5" Grid.Column="1" Grid.ColumnSpan="2" Grid.RowSpan="1" Name="textBoxWasteDisposalServiceProviders" Text="{Binding WasteDisposalServiceProviderText, Converter={util:TrimStringConverter}}" Margin="2" />
<Label Grid.Row="6" Grid.Column="0" HorizontalContentAlignment="Right" Content="{x:Static p:Resources.textAgentTemplate}" Margin="0,0,10,0" />
<Grid Grid.Row="6" Grid.Column="1" Grid.ColumnSpan="2">
<Grid Grid.Row="6" Grid.Column="1" Grid.ColumnSpan="2" x:Name="gridWasteControls">
<Grid.ColumnDefinitions>
<ColumnDefinition Width=".25*" />
<ColumnDefinition Width=".25*" />

View File

@ -170,6 +170,8 @@ namespace ENI2.SheetDisplayControls
this.dataGridLADG.CreateRequested += DataGridLADG_CreateRequested;
// 2.7
this.checkBoxValidExemption.Checked += CheckBoxValidExemption_Checked;
this.checkBoxValidExemption.Unchecked += CheckBoxValidExemption_Checked;
this.checkBoxAccurateCorrectDetails.DataContext = _was;
this.checkBoxValidExemption.DataContext = _was;
this.dataGridWaste.Initialize();
@ -200,6 +202,17 @@ namespace ENI2.SheetDisplayControls
}
private void CheckBoxValidExemption_Checked(object sender, RoutedEventArgs e)
{
bool on = !(this.checkBoxValidExemption.IsChecked ?? false);
this.checkBoxAccurateCorrectDetails.IsEnabled = on;
this.locodeCtrlLastWastePort.IsEnabled = on;
this.datePickerDateLastDisposal.IsEnabled = on;
this.textBoxWasteDisposalServiceProviders.IsEnabled = on;
this.gridWasteControls.IsEnabled = on;
this.dataGridWaste.IsEnabled = on;
}
public override void SetEnabled(bool enabled)
{
base.SetEnabled(enabled);

View File

@ -147,7 +147,7 @@
<TextBlock FontSize="18" VerticalAlignment="Bottom" Text="{x:Static p:Resources.text52SSCEC}" Grid.Column="0" Grid.Row="0" Grid.ColumnSpan="2"/>
<Label HorizontalContentAlignment="Right" Grid.Row="1" Grid.Column="0" Content="{x:Static p:Resources.textSimplificationAvailable}" Name="label_MDHSimplificationAvailable" Margin="0,0,10,0"/>
<Label HorizontalContentAlignment="Right" Grid.Row="1" Grid.Column="0" Content="{x:Static p:Resources.textMDHSimplification}" Name="label_MDHSimplificationAvailable" Margin="0,0,10,0"/>
<CheckBox Name="checkSimplification" IsChecked="{Binding MDHSimplification}" Grid.Row="1" Grid.Column="1" VerticalAlignment="Center"/>
<Label HorizontalContentAlignment="Right" Grid.Row="2" Grid.Column="0" Content="{x:Static p:Resources.textPortOfHealth}" Name="label_PortOfHealth" Margin="0,0,10,0"/>
<enictrl:LocodeControl x:Name="locodePortWhereHealthDeclarationWasGiven" Grid.Row="2" Grid.Column="1" LocodeValue="{Binding PortOfCallWhereCompleteMDHNotified, Mode=TwoWay}" />
@ -166,7 +166,7 @@
<CheckBox Name="checkBoxReinspectionSanitary" IsChecked="{Binding SanitaryControlReinspectionRequired}" Grid.Row="6" Grid.Column="1" VerticalAlignment="Center"/>
<TextBlock FontSize="18" VerticalAlignment="Bottom" Text="{x:Static p:Resources.text53ISPS}" Grid.Column="0" Grid.Row="7" Grid.ColumnSpan="2"/>
<Label HorizontalContentAlignment="Right" Grid.Row="8" Grid.Column="0" Content="{x:Static p:Resources.textSimplificationAvailable}" Name="label_SimplificationAvailable" Margin="0,0,10,0"/>
<Label HorizontalContentAlignment="Right" Grid.Row="8" Grid.Column="0" Content="{x:Static p:Resources.textSECSimplification}" Name="label_SimplificationAvailable" Margin="0,0,10,0"/>
<CheckBox Name="checkBoxSECSimplification" IsChecked="{Binding SECSimplification}" Grid.Row="8" Grid.Column="1" VerticalAlignment="Center"/>
<Label HorizontalContentAlignment="Right" Grid.Row="9" Grid.Column="0" Content="{x:Static p:Resources.textPortWhereSimplWasGiven}" Name="label_PortWhereSimplWasGiven" Margin="0,0,10,0"/>
<enictrl:LocodeControl x:Name="locodePortOfCallWhereCompleteSECNotified" Grid.Row="9" Grid.Column="1" LocodeValue="{Binding PortOfCallWhereCompleteSECNotified, Mode=TwoWay}" />

View File

@ -107,11 +107,11 @@
<Grid.RowDefinitions>
<RowDefinition Height="36" />
<RowDefinition Height="28" />
<RowDefinition Height="300" />
<RowDefinition Height="260" />
<RowDefinition Height="36" />
<RowDefinition Height="28" />
<RowDefinition Height="220" />
<RowDefinition Height="260" />
<RowDefinition Height="36" />
<RowDefinition Height="28" />

View File

@ -71,6 +71,11 @@
</DataGridTemplateColumn.CellTemplate>
</DataGridTemplateColumn-->
<DataGridTextColumn Header="{x:Static p:Resources.textAmountWasteReceived_MTQ}" IsReadOnly="False" Width="0.15*">
<DataGridTextColumn.ElementStyle>
<Style TargetType="TextBlock">
<Setter Property="HorizontalAlignment" Value="Center" />
</Style>
</DataGridTextColumn.ElementStyle>
<DataGridTextColumn.Binding>
<Binding Path="AmountWasteReceived_MTQ" Mode="TwoWay" StringFormat="N3" >
<Binding.ValidationRules>