If the agency provided a time, display it in the BSMD column. Also corrected ETD/ETA Label right there
This commit is contained in:
parent
b070979723
commit
effbf42303
@ -268,22 +268,9 @@ namespace BreCalClient
|
||||
else
|
||||
this.imageEvaluation.ToolTip = null;
|
||||
|
||||
//Times? bsmdTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.BSMD);
|
||||
//if (bsmdTimes != null)
|
||||
this.textBlockBerth.Text = this.ShipcallControlModel?.GetBerthText(null);
|
||||
//else
|
||||
// this.textBlockBerth.Text = this.ShipcallControlModel?.Berth;
|
||||
|
||||
this.textBlockBerth.Text = this.ShipcallControlModel?.GetBerthText(null);
|
||||
this.textBlockCallsign.Text = this.ShipcallControlModel?.Ship?.Callsign;
|
||||
if (this.ShipcallControlModel?.Shipcall?.Type == ShipcallType.Arrival)
|
||||
{
|
||||
this.textBlockETA.Text = this.ShipcallControlModel?.Shipcall?.Eta?.ToString("dd.MM. HH:mm");
|
||||
}
|
||||
if ((this.ShipcallControlModel?.Shipcall?.Type == ShipcallType.Departure) || (this.ShipcallControlModel?.Shipcall?.Type == ShipcallType.Shifting))
|
||||
{
|
||||
this.labelETA.Text = "ETD";
|
||||
this.textBlockETA.Text = this.ShipcallControlModel?.Shipcall?.Etd?.ToString("dd.MM. HH:mm");
|
||||
}
|
||||
this.textBlockETA.Text = this.ShipcallControlModel?.GetETAETD(true);
|
||||
|
||||
this.textBlockIMO.Text = this.ShipcallControlModel?.Ship?.Imo.ToString();
|
||||
this.textBlockLengthWidth.Text = $"{this.ShipcallControlModel?.Ship?.Length} / {this.ShipcallControlModel?.Ship?.Width}";
|
||||
@ -293,6 +280,7 @@ namespace BreCalClient
|
||||
|
||||
if (this.ShipcallControlModel?.Shipcall?.Type != ShipcallType.Arrival)
|
||||
{
|
||||
this.labelETA.Text = "ETD";
|
||||
this.labelETAETDAgent.Content = "ETD";
|
||||
this.labelETAETDMooring.Content = "ETD";
|
||||
this.labelETAETDPilot.Content = "ETD";
|
||||
|
||||
@ -219,7 +219,7 @@ namespace BreCalClient
|
||||
return berthText;
|
||||
}
|
||||
|
||||
public string GetETAETD()
|
||||
public string GetETAETD(bool useShortVersion = false)
|
||||
{
|
||||
DateTime theDate = DateTime.Now;
|
||||
if(this.Shipcall != null)
|
||||
@ -243,6 +243,8 @@ namespace BreCalClient
|
||||
theDate = agentTimes.EtdBerth.Value;
|
||||
}
|
||||
}
|
||||
if(useShortVersion)
|
||||
return theDate.ToString("dd.MM. HH:mm");
|
||||
return theDate.ToString();
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user