Port may only be changed if the shipcall is created

This commit is contained in:
Daniel Schick 2024-12-02 08:15:23 +01:00
parent 0d9e4ac026
commit 184d15554b
2 changed files with 5 additions and 1 deletions

View File

@ -42,6 +42,8 @@ namespace BreCalClient
public ShipApi? ShipApi { get; set; }
public bool IsCreate { get; set; } = false;
#endregion
#region Event handler
@ -395,6 +397,7 @@ namespace BreCalClient
this.datePickerETD.IsEnabled = isAgency || isBsmd;
this.labelBSMDGranted.Visibility = editRightGrantedForBSMD ? Visibility.Visible : Visibility.Hidden;
this.comboBoxHarbour.IsEnabled = this.IsCreate;
this.comboBoxCategories_SelectionChanged(null, null);
}

View File

@ -247,7 +247,8 @@ namespace BreCalClient
EditShipcallControl esc = new()
{
ShipEditingEnabled = App.Participant.IsTypeFlagSet(Extensions.ParticipantType.BSMD),
ShipApi = _shipApi
ShipApi = _shipApi,
IsCreate = true
};
if (model != null)
esc.ShipcallModel = model;