Set fixed order in shipcall control by using a tooltip enabled icon with a closed lock
This commit is contained in:
parent
d1c3115a8f
commit
7894ba0323
9
src/BreCalClient/Resources/Resources.Designer.cs
generated
9
src/BreCalClient/Resources/Resources.Designer.cs
generated
@ -602,6 +602,15 @@ namespace BreCalClient.Resources {
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to Marked as a fixed order.
|
||||
/// </summary>
|
||||
public static string textFixedOrder {
|
||||
get {
|
||||
return ResourceManager.GetString("textFixedOrder", resourceCulture);
|
||||
}
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Looks up a localized string similar to from.
|
||||
/// </summary>
|
||||
|
||||
@ -469,4 +469,7 @@
|
||||
<data name="textTimestamp" xml:space="preserve">
|
||||
<value>Zeitpunkt</value>
|
||||
</data>
|
||||
<data name="textFixedOrder" xml:space="preserve">
|
||||
<value>Als feste Bestellung vermerkt</value>
|
||||
</data>
|
||||
</root>
|
||||
@ -289,6 +289,9 @@
|
||||
<data name="textFixed" xml:space="preserve">
|
||||
<value>Fixed</value>
|
||||
</data>
|
||||
<data name="textFixedOrder" xml:space="preserve">
|
||||
<value>Marked as a fixed order</value>
|
||||
</data>
|
||||
<data name="textFrom" xml:space="preserve">
|
||||
<value>from</value>
|
||||
</data>
|
||||
|
||||
@ -144,6 +144,7 @@
|
||||
<Label Grid.Row="0" x:Name="labelETAETDMooring" Grid.Column="0" Content="ETA" Padding="0" VerticalContentAlignment="Center" />
|
||||
<Label Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2" Content="{x:Static p:Resources.textRemarks}" Padding="0" VerticalContentAlignment="Top" FontSize="9"/>
|
||||
<Label Grid.Row="0" Grid.Column="1" Padding="0" VerticalContentAlignment="Center" x:Name="labelMooringETAETDValue" FontWeight="DemiBold"/>
|
||||
<Image Grid.Row="1" Grid.Column="0" x:Name="imageMooringLocked" VerticalAlignment="Top" Margin="0 20 0 0" HorizontalAlignment="Left" Source="./Resources/lock.png" Width="16" Height="16" ToolTip="{x:Static p:Resources.textFixedOrder}"/>
|
||||
<TextBlock Grid.Row="1" Grid.Column="1" Padding="0" TextWrapping="Wrap" VerticalAlignment="Top" x:Name="textBlockMooringRemarks"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
@ -162,6 +163,7 @@
|
||||
<Label Grid.Row="0" Grid.Column="0" x:Name="labelETAETDPortAuthority" Content="ETA" Padding="0" VerticalContentAlignment="Center" />
|
||||
<Label Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2" Content="{x:Static p:Resources.textRemarks}" Padding="0" VerticalContentAlignment="Top" FontSize="9"/>
|
||||
<Label Grid.Row="0" Grid.Column="1" Padding="0" VerticalContentAlignment="Center" x:Name="labelPortAuthorityETAETDValue" FontWeight="DemiBold"/>
|
||||
<Image Grid.Row="1" Grid.Column="0" x:Name="imagePortAuthorityLocked" VerticalAlignment="Top" Margin="0 20 0 0" HorizontalAlignment="Left" Source="./Resources/lock.png" Width="16" Height="16" ToolTip="{x:Static p:Resources.textFixedOrder}"/>
|
||||
<TextBlock Grid.Row="1" Grid.Column="1" Padding="0" TextWrapping="Wrap" VerticalAlignment="Top" x:Name="textBlockPortAuthorityRemarks"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
@ -179,6 +181,7 @@
|
||||
<Label Grid.Row="0" Grid.Column="0" x:Name="labelETAETDPilot" Content="ETA" Padding="0" VerticalContentAlignment="Center" />
|
||||
<Label Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2" Content="{x:Static p:Resources.textRemarks}" Padding="0" VerticalContentAlignment="Top" FontSize="9"/>
|
||||
<Label Grid.Row="0" Grid.Column="1" Padding="0" VerticalContentAlignment="Center" x:Name="labelPilotETAETDValue" FontWeight="DemiBold"/>
|
||||
<Image Grid.Row="1" Grid.Column="0" x:Name="imagePilotLocked" VerticalAlignment="Top" Margin="0 20 0 0" HorizontalAlignment="Left" Source="./Resources/lock.png" Width="16" Height="16" ToolTip="{x:Static p:Resources.textFixedOrder}"/>
|
||||
<TextBlock Grid.Row="1" Grid.Column="1" Padding="0" TextWrapping="Wrap" VerticalAlignment="Top" x:Name="textBlockPilotRemarks"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
@ -196,6 +199,7 @@
|
||||
<Label Grid.Row="0" Grid.Column="0" x:Name="labelETAETDTug" Content="ETA" Padding="0" VerticalContentAlignment="Center" />
|
||||
<Label Grid.Row="1" Grid.Column="0" Grid.ColumnSpan="2" Content="{x:Static p:Resources.textRemarks}" Padding="0" VerticalContentAlignment="Top" FontSize="9"/>
|
||||
<Label Grid.Row="0" Grid.Column="1" Padding="0" VerticalContentAlignment="Center" x:Name="labelTugETAETDValue" FontWeight="DemiBold"/>
|
||||
<Image Grid.Row="1" Grid.Column="0" x:Name="imageTugLocked" VerticalAlignment="Top" Margin="0 20 0 0" HorizontalAlignment="Left" Source="./Resources/lock.png" Width="16" Height="16" ToolTip="{x:Static p:Resources.textFixedOrder}"/>
|
||||
<TextBlock Grid.Row="1" Grid.Column="1" Padding="0" TextWrapping="Wrap" VerticalAlignment="Top" x:Name="textBlockTugRemarks"/>
|
||||
</Grid>
|
||||
</Border>
|
||||
|
||||
@ -327,13 +327,7 @@ namespace BreCalClient
|
||||
this.textBlockDraft.Text = "";
|
||||
}
|
||||
|
||||
Times? mooringTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.MOORING);
|
||||
|
||||
// here dynamically add and remove the lock icon defined as such to the correct grid cell
|
||||
// <Image Grid.Row="1" Grid.Column="0" VerticalAlignment="Top" Margin="0 20 0 0" HorizontalAlignment="Left" Source="./Resources/lock.png" Width="16" Height="16" />
|
||||
// Grid.SetRow(1
|
||||
// gridMooring.Children.Add(.)
|
||||
// NO MUCH BETTER WE PUT THE ICON IN and just set the visibility TO HIDDEN!!!
|
||||
Times? mooringTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.MOORING);
|
||||
|
||||
if (mooringTimes != null)
|
||||
{
|
||||
@ -344,11 +338,13 @@ namespace BreCalClient
|
||||
{
|
||||
this.labelMooringETAETDValue.Content = mooringTimes.EtdBerth.HasValue ? mooringTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -";
|
||||
}
|
||||
this.imageMooringLocked.Visibility = (mooringTimes.EtaBerthFixed ?? false) ? Visibility.Visible : Visibility.Hidden;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.labelMooringETAETDValue.Content = "- / ";
|
||||
this.textBlockMooringRemarks.Text = "";
|
||||
this.imageMooringLocked.Visibility = Visibility.Hidden;
|
||||
}
|
||||
|
||||
Times? portAuthorityTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.PORT_ADMINISTRATION);
|
||||
@ -360,11 +356,13 @@ namespace BreCalClient
|
||||
{
|
||||
this.labelPortAuthorityETAETDValue.Content = portAuthorityTimes.EtdBerth.HasValue ? portAuthorityTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -";
|
||||
}
|
||||
this.imagePortAuthorityLocked.Visibility = (portAuthorityTimes.EtaBerthFixed ?? false) ? Visibility.Visible : Visibility.Hidden;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.labelPortAuthorityETAETDValue.Content = "- / -";
|
||||
this.textBlockPortAuthorityRemarks.Text = "";
|
||||
this.imagePortAuthorityLocked.Visibility = Visibility.Hidden;
|
||||
}
|
||||
|
||||
Times? pilotTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.PILOT);
|
||||
@ -376,11 +374,13 @@ namespace BreCalClient
|
||||
{
|
||||
this.labelPilotETAETDValue.Content = pilotTimes.EtdBerth.HasValue ? pilotTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -";
|
||||
}
|
||||
this.imagePilotLocked.Visibility = (pilotTimes.EtaBerthFixed ?? false) ? Visibility.Visible : Visibility.Hidden;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.labelPilotETAETDValue.Content = "- / -";
|
||||
this.textBlockPilotRemarks.Text = "";
|
||||
this.imagePilotLocked.Visibility = Visibility.Hidden;
|
||||
}
|
||||
|
||||
Times? tugTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.TUG);
|
||||
@ -392,11 +392,13 @@ namespace BreCalClient
|
||||
{
|
||||
this.labelTugETAETDValue.Content = tugTimes.EtdBerth.HasValue ? tugTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -";
|
||||
}
|
||||
this.imageTugLocked.Visibility = (tugTimes.EtaBerthFixed ?? false) ? Visibility.Visible : Visibility.Hidden;
|
||||
}
|
||||
else
|
||||
{
|
||||
this.labelTugETAETDValue.Content = "- / -";
|
||||
this.textBlockTugRemarks.Text = "";
|
||||
this.imageTugLocked.Visibility = Visibility.Hidden;
|
||||
}
|
||||
|
||||
Times? terminalTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.TERMINAL);
|
||||
|
||||
Reference in New Issue
Block a user