fixed merge

This commit is contained in:
Daniel Schick 2024-04-02 11:31:38 +02:00
commit 1dfa4e7b5e
28 changed files with 849 additions and 280 deletions

View File

@ -1,7 +1,7 @@
//---------------------- //----------------------
// <auto-generated> // <auto-generated>
// Generated REST API Client Code Generator v1.9.8.0 on 31.03.2024 21:55:59 // Generated REST API Client Code Generator v1.9.8.0 on 28.03.2024 17:58:20
// Using the tool OpenAPI Generator v7.4.0 // Using the tool OpenAPI Generator v7.4.0
// </auto-generated> // </auto-generated>
//---------------------- //----------------------
@ -1544,9 +1544,10 @@ namespace BreCalClient.misc.Api
/// This endpoint returns a list of changes made to the specific shipcall /// This endpoint returns a list of changes made to the specific shipcall
/// </remarks> /// </remarks>
/// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception> /// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="shipcallId">**Id of ship call**. *Example: 52*. Id given in ship call list</param>
/// <param name="operationIndex">Index associated with the operation.</param> /// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;History&gt;</returns> /// <returns>List&lt;History&gt;</returns>
List<History> HistoryGet(int operationIndex = 0); List<History> HistoryGet(int shipcallId, int operationIndex = 0);
/// <summary> /// <summary>
/// History data /// History data
/// </summary> /// </summary>
@ -1554,9 +1555,10 @@ namespace BreCalClient.misc.Api
/// This endpoint returns a list of changes made to the specific shipcall /// This endpoint returns a list of changes made to the specific shipcall
/// </remarks> /// </remarks>
/// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception> /// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="shipcallId">**Id of ship call**. *Example: 52*. Id given in ship call list</param>
/// <param name="operationIndex">Index associated with the operation.</param> /// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;History&gt;</returns> /// <returns>ApiResponse of List&lt;History&gt;</returns>
ApiResponse<List<History>> HistoryGetWithHttpInfo(int operationIndex = 0); ApiResponse<List<History>> HistoryGetWithHttpInfo(int shipcallId, int operationIndex = 0);
/// <summary> /// <summary>
/// Gets a list of notifications pursuant to a specified participant and ship call /// Gets a list of notifications pursuant to a specified participant and ship call
/// </summary> /// </summary>
@ -1638,10 +1640,11 @@ namespace BreCalClient.misc.Api
/// This endpoint returns a list of changes made to the specific shipcall /// This endpoint returns a list of changes made to the specific shipcall
/// </remarks> /// </remarks>
/// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception> /// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="shipcallId">**Id of ship call**. *Example: 52*. Id given in ship call list</param>
/// <param name="operationIndex">Index associated with the operation.</param> /// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param> /// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;History&gt;</returns> /// <returns>Task of List&lt;History&gt;</returns>
System.Threading.Tasks.Task<List<History>> HistoryGetAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); System.Threading.Tasks.Task<List<History>> HistoryGetAsync(int shipcallId, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary> /// <summary>
/// History data /// History data
/// </summary> /// </summary>
@ -1649,10 +1652,11 @@ namespace BreCalClient.misc.Api
/// This endpoint returns a list of changes made to the specific shipcall /// This endpoint returns a list of changes made to the specific shipcall
/// </remarks> /// </remarks>
/// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception> /// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="shipcallId">**Id of ship call**. *Example: 52*. Id given in ship call list</param>
/// <param name="operationIndex">Index associated with the operation.</param> /// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param> /// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;History&gt;)</returns> /// <returns>Task of ApiResponse (List&lt;History&gt;)</returns>
System.Threading.Tasks.Task<ApiResponse<List<History>>> HistoryGetWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)); System.Threading.Tasks.Task<ApiResponse<List<History>>> HistoryGetWithHttpInfoAsync(int shipcallId, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken));
/// <summary> /// <summary>
/// Gets a list of notifications pursuant to a specified participant and ship call /// Gets a list of notifications pursuant to a specified participant and ship call
/// </summary> /// </summary>
@ -1922,20 +1926,22 @@ namespace BreCalClient.misc.Api
/// History data This endpoint returns a list of changes made to the specific shipcall /// History data This endpoint returns a list of changes made to the specific shipcall
/// </summary> /// </summary>
/// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception> /// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="shipcallId">**Id of ship call**. *Example: 52*. Id given in ship call list</param>
/// <param name="operationIndex">Index associated with the operation.</param> /// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>List&lt;History&gt;</returns> /// <returns>List&lt;History&gt;</returns>
public List<History> HistoryGet(int operationIndex = 0) public List<History> HistoryGet(int shipcallId, int operationIndex = 0)
{ {
BreCalClient.misc.Client.ApiResponse<List<History>> localVarResponse = HistoryGetWithHttpInfo(); BreCalClient.misc.Client.ApiResponse<List<History>> localVarResponse = HistoryGetWithHttpInfo(shipcallId);
return localVarResponse.Data; return localVarResponse.Data;
} }
/// <summary> /// <summary>
/// History data This endpoint returns a list of changes made to the specific shipcall /// History data This endpoint returns a list of changes made to the specific shipcall
/// </summary> /// </summary>
/// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception> /// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="shipcallId">**Id of ship call**. *Example: 52*. Id given in ship call list</param>
/// <param name="operationIndex">Index associated with the operation.</param> /// <param name="operationIndex">Index associated with the operation.</param>
/// <returns>ApiResponse of List&lt;History&gt;</returns> /// <returns>ApiResponse of List&lt;History&gt;</returns>
public BreCalClient.misc.Client.ApiResponse<List<History>> HistoryGetWithHttpInfo(int operationIndex = 0) public BreCalClient.misc.Client.ApiResponse<List<History>> HistoryGetWithHttpInfo(int shipcallId, int operationIndex = 0)
{ {
BreCalClient.misc.Client.RequestOptions localVarRequestOptions = new BreCalClient.misc.Client.RequestOptions(); BreCalClient.misc.Client.RequestOptions localVarRequestOptions = new BreCalClient.misc.Client.RequestOptions();
string[] _contentTypes = new string[] { string[] _contentTypes = new string[] {
@ -1954,6 +1960,7 @@ namespace BreCalClient.misc.Api
{ {
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
} }
localVarRequestOptions.QueryParameters.Add(BreCalClient.misc.Client.ClientUtils.ParameterToMultiMap("", "shipcall_id", shipcallId));
localVarRequestOptions.Operation = "StaticApi.HistoryGet"; localVarRequestOptions.Operation = "StaticApi.HistoryGet";
localVarRequestOptions.OperationIndex = operationIndex; localVarRequestOptions.OperationIndex = operationIndex;
// authentication (ApiKey) required // authentication (ApiKey) required
@ -1977,22 +1984,24 @@ namespace BreCalClient.misc.Api
/// History data This endpoint returns a list of changes made to the specific shipcall /// History data This endpoint returns a list of changes made to the specific shipcall
/// </summary> /// </summary>
/// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception> /// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="shipcallId">**Id of ship call**. *Example: 52*. Id given in ship call list</param>
/// <param name="operationIndex">Index associated with the operation.</param> /// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param> /// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of List&lt;History&gt;</returns> /// <returns>Task of List&lt;History&gt;</returns>
public async System.Threading.Tasks.Task<List<History>> HistoryGetAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) public async System.Threading.Tasks.Task<List<History>> HistoryGetAsync(int shipcallId, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{ {
BreCalClient.misc.Client.ApiResponse<List<History>> localVarResponse = await HistoryGetWithHttpInfoAsync(operationIndex, cancellationToken).ConfigureAwait(false); BreCalClient.misc.Client.ApiResponse<List<History>> localVarResponse = await HistoryGetWithHttpInfoAsync(shipcallId, operationIndex, cancellationToken).ConfigureAwait(false);
return localVarResponse.Data; return localVarResponse.Data;
} }
/// <summary> /// <summary>
/// History data This endpoint returns a list of changes made to the specific shipcall /// History data This endpoint returns a list of changes made to the specific shipcall
/// </summary> /// </summary>
/// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception> /// <exception cref="BreCalClient.misc.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="shipcallId">**Id of ship call**. *Example: 52*. Id given in ship call list</param>
/// <param name="operationIndex">Index associated with the operation.</param> /// <param name="operationIndex">Index associated with the operation.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param> /// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <returns>Task of ApiResponse (List&lt;History&gt;)</returns> /// <returns>Task of ApiResponse (List&lt;History&gt;)</returns>
public async System.Threading.Tasks.Task<BreCalClient.misc.Client.ApiResponse<List<History>>> HistoryGetWithHttpInfoAsync(int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken)) public async System.Threading.Tasks.Task<BreCalClient.misc.Client.ApiResponse<List<History>>> HistoryGetWithHttpInfoAsync(int shipcallId, int operationIndex = 0, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
{ {
BreCalClient.misc.Client.RequestOptions localVarRequestOptions = new BreCalClient.misc.Client.RequestOptions(); BreCalClient.misc.Client.RequestOptions localVarRequestOptions = new BreCalClient.misc.Client.RequestOptions();
string[] _contentTypes = new string[] { string[] _contentTypes = new string[] {
@ -2011,6 +2020,7 @@ namespace BreCalClient.misc.Api
{ {
localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept); localVarRequestOptions.HeaderParameters.Add("Accept", localVarAccept);
} }
localVarRequestOptions.QueryParameters.Add(BreCalClient.misc.Client.ClientUtils.ParameterToMultiMap("", "shipcall_id", shipcallId));
localVarRequestOptions.Operation = "StaticApi.HistoryGet"; localVarRequestOptions.Operation = "StaticApi.HistoryGet";
localVarRequestOptions.OperationIndex = operationIndex; localVarRequestOptions.OperationIndex = operationIndex;
// authentication (ApiKey) required // authentication (ApiKey) required
@ -4879,7 +4889,7 @@ namespace BreCalClient.misc.Client
/// <summary> /// <summary>
/// Gets or sets the base path for API access. /// Gets or sets the base path for API access.
/// </summary> /// </summary>
public virtual string BasePath public virtual string BasePath
{ {
get { return _basePath; } get { return _basePath; }
set { _basePath = value; } set { _basePath = value; }
@ -6276,41 +6286,41 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Id == input.Id || this.Id == input.Id ||
this.Id.Equals(input.Id) this.Id.Equals(input.Id)
) && ) &&
( (
this.Name == input.Name || this.Name == input.Name ||
(this.Name != null && (this.Name != null &&
this.Name.Equals(input.Name)) this.Name.Equals(input.Name))
) && ) &&
( (
this.OwnerId == input.OwnerId || this.OwnerId == input.OwnerId ||
(this.OwnerId != null && (this.OwnerId != null &&
this.OwnerId.Equals(input.OwnerId)) this.OwnerId.Equals(input.OwnerId))
) && ) &&
( (
this.AuthorityId == input.AuthorityId || this.AuthorityId == input.AuthorityId ||
(this.AuthorityId != null && (this.AuthorityId != null &&
this.AuthorityId.Equals(input.AuthorityId)) this.AuthorityId.Equals(input.AuthorityId))
) && ) &&
( (
this.VarLock == input.VarLock || this.VarLock == input.VarLock ||
(this.VarLock != null && (this.VarLock != null &&
this.VarLock.Equals(input.VarLock)) this.VarLock.Equals(input.VarLock))
) && ) &&
( (
this.Created == input.Created || this.Created == input.Created ||
(this.Created != null && (this.Created != null &&
this.Created.Equals(input.Created)) this.Created.Equals(input.Created))
) && ) &&
( (
this.Modified == input.Modified || this.Modified == input.Modified ||
(this.Modified != null && (this.Modified != null &&
this.Modified.Equals(input.Modified)) this.Modified.Equals(input.Modified))
) && ) &&
( (
this.Deleted == input.Deleted || this.Deleted == input.Deleted ||
this.Deleted.Equals(input.Deleted) this.Deleted.Equals(input.Deleted)
@ -6464,12 +6474,12 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Username == input.Username || this.Username == input.Username ||
(this.Username != null && (this.Username != null &&
this.Username.Equals(input.Username)) this.Username.Equals(input.Username))
) && ) &&
( (
this.Password == input.Password || this.Password == input.Password ||
(this.Password != null && (this.Password != null &&
@ -6589,7 +6599,7 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Message == input.Message || this.Message == input.Message ||
(this.Message != null && (this.Message != null &&
@ -6782,33 +6792,33 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Id == input.Id || this.Id == input.Id ||
this.Id.Equals(input.Id) this.Id.Equals(input.Id)
) && ) &&
( (
this.ParticipantId == input.ParticipantId || this.ParticipantId == input.ParticipantId ||
this.ParticipantId.Equals(input.ParticipantId) this.ParticipantId.Equals(input.ParticipantId)
) && ) &&
( (
this.ShipcallId == input.ShipcallId || this.ShipcallId == input.ShipcallId ||
this.ShipcallId.Equals(input.ShipcallId) this.ShipcallId.Equals(input.ShipcallId)
) && ) &&
( (
this.Timestamp == input.Timestamp || this.Timestamp == input.Timestamp ||
(this.Timestamp != null && (this.Timestamp != null &&
this.Timestamp.Equals(input.Timestamp)) this.Timestamp.Equals(input.Timestamp))
) && ) &&
( (
this.Eta == input.Eta || this.Eta == input.Eta ||
(this.Eta != null && (this.Eta != null &&
this.Eta.Equals(input.Eta)) this.Eta.Equals(input.Eta))
) && ) &&
( (
this.Operation == input.Operation || this.Operation == input.Operation ||
this.Operation.Equals(input.Operation) this.Operation.Equals(input.Operation)
) && ) &&
( (
this.Type == input.Type || this.Type == input.Type ||
this.Type.Equals(input.Type) this.Type.Equals(input.Type)
@ -6921,7 +6931,7 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.VarId == input.VarId || this.VarId == input.VarId ||
this.VarId.Equals(input.VarId) this.VarId.Equals(input.VarId)
@ -7086,44 +7096,44 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Id == input.Id || this.Id == input.Id ||
this.Id.Equals(input.Id) this.Id.Equals(input.Id)
) && ) &&
( (
this.ParticipantId == input.ParticipantId || this.ParticipantId == input.ParticipantId ||
this.ParticipantId.Equals(input.ParticipantId) this.ParticipantId.Equals(input.ParticipantId)
) && ) &&
( (
this.FirstName == input.FirstName || this.FirstName == input.FirstName ||
(this.FirstName != null && (this.FirstName != null &&
this.FirstName.Equals(input.FirstName)) this.FirstName.Equals(input.FirstName))
) && ) &&
( (
this.LastName == input.LastName || this.LastName == input.LastName ||
(this.LastName != null && (this.LastName != null &&
this.LastName.Equals(input.LastName)) this.LastName.Equals(input.LastName))
) && ) &&
( (
this.UserName == input.UserName || this.UserName == input.UserName ||
(this.UserName != null && (this.UserName != null &&
this.UserName.Equals(input.UserName)) this.UserName.Equals(input.UserName))
) && ) &&
( (
this.UserPhone == input.UserPhone || this.UserPhone == input.UserPhone ||
(this.UserPhone != null && (this.UserPhone != null &&
this.UserPhone.Equals(input.UserPhone)) this.UserPhone.Equals(input.UserPhone))
) && ) &&
( (
this.UserEmail == input.UserEmail || this.UserEmail == input.UserEmail ||
(this.UserEmail != null && (this.UserEmail != null &&
this.UserEmail.Equals(input.UserEmail)) this.UserEmail.Equals(input.UserEmail))
) && ) &&
( (
this.Exp == input.Exp || this.Exp == input.Exp ||
this.Exp.Equals(input.Exp) this.Exp.Equals(input.Exp)
) && ) &&
( (
this.Token == input.Token || this.Token == input.Token ||
(this.Token != null && (this.Token != null &&
@ -7293,29 +7303,29 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Id == input.Id || this.Id == input.Id ||
this.Id.Equals(input.Id) this.Id.Equals(input.Id)
) && ) &&
( (
this.ShipcallId == input.ShipcallId || this.ShipcallId == input.ShipcallId ||
this.ShipcallId.Equals(input.ShipcallId) this.ShipcallId.Equals(input.ShipcallId)
) && ) &&
( (
this.NotificationType == input.NotificationType || this.NotificationType == input.NotificationType ||
this.NotificationType.Equals(input.NotificationType) this.NotificationType.Equals(input.NotificationType)
) && ) &&
( (
this.Message == input.Message || this.Message == input.Message ||
(this.Message != null && (this.Message != null &&
this.Message.Equals(input.Message)) this.Message.Equals(input.Message))
) && ) &&
( (
this.Created == input.Created || this.Created == input.Created ||
(this.Created != null && (this.Created != null &&
this.Created.Equals(input.Created)) this.Created.Equals(input.Created))
) && ) &&
( (
this.Modified == input.Modified || this.Modified == input.Modified ||
(this.Modified != null && (this.Modified != null &&
@ -7611,50 +7621,50 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Id == input.Id || this.Id == input.Id ||
this.Id.Equals(input.Id) this.Id.Equals(input.Id)
) && ) &&
( (
this.Name == input.Name || this.Name == input.Name ||
(this.Name != null && (this.Name != null &&
this.Name.Equals(input.Name)) this.Name.Equals(input.Name))
) && ) &&
( (
this.Street == input.Street || this.Street == input.Street ||
(this.Street != null && (this.Street != null &&
this.Street.Equals(input.Street)) this.Street.Equals(input.Street))
) && ) &&
( (
this.PostalCode == input.PostalCode || this.PostalCode == input.PostalCode ||
(this.PostalCode != null && (this.PostalCode != null &&
this.PostalCode.Equals(input.PostalCode)) this.PostalCode.Equals(input.PostalCode))
) && ) &&
( (
this.City == input.City || this.City == input.City ||
(this.City != null && (this.City != null &&
this.City.Equals(input.City)) this.City.Equals(input.City))
) && ) &&
( (
this.Type == input.Type || this.Type == input.Type ||
this.Type.Equals(input.Type) this.Type.Equals(input.Type)
) && ) &&
( (
this.Flags == input.Flags || this.Flags == input.Flags ||
(this.Flags != null && (this.Flags != null &&
this.Flags.Equals(input.Flags)) this.Flags.Equals(input.Flags))
) && ) &&
( (
this.Created == input.Created || this.Created == input.Created ||
(this.Created != null && (this.Created != null &&
this.Created.Equals(input.Created)) this.Created.Equals(input.Created))
) && ) &&
( (
this.Modified == input.Modified || this.Modified == input.Modified ||
(this.Modified != null && (this.Modified != null &&
this.Modified.Equals(input.Modified)) this.Modified.Equals(input.Modified))
) && ) &&
( (
this.Deleted == input.Deleted || this.Deleted == input.Deleted ||
this.Deleted.Equals(input.Deleted) this.Deleted.Equals(input.Deleted)
@ -7819,11 +7829,11 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.ParticipantId == input.ParticipantId || this.ParticipantId == input.ParticipantId ||
this.ParticipantId.Equals(input.ParticipantId) this.ParticipantId.Equals(input.ParticipantId)
) && ) &&
( (
this.Type == input.Type || this.Type == input.Type ||
this.Type.Equals(input.Type) this.Type.Equals(input.Type)
@ -8023,65 +8033,65 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Id == input.Id || this.Id == input.Id ||
this.Id.Equals(input.Id) this.Id.Equals(input.Id)
) && ) &&
( (
this.Name == input.Name || this.Name == input.Name ||
(this.Name != null && (this.Name != null &&
this.Name.Equals(input.Name)) this.Name.Equals(input.Name))
) && ) &&
( (
this.Imo == input.Imo || this.Imo == input.Imo ||
(this.Imo != null && (this.Imo != null &&
this.Imo.Equals(input.Imo)) this.Imo.Equals(input.Imo))
) && ) &&
( (
this.Callsign == input.Callsign || this.Callsign == input.Callsign ||
(this.Callsign != null && (this.Callsign != null &&
this.Callsign.Equals(input.Callsign)) this.Callsign.Equals(input.Callsign))
) && ) &&
( (
this.ParticipantId == input.ParticipantId || this.ParticipantId == input.ParticipantId ||
(this.ParticipantId != null && (this.ParticipantId != null &&
this.ParticipantId.Equals(input.ParticipantId)) this.ParticipantId.Equals(input.ParticipantId))
) && ) &&
( (
this.Length == input.Length || this.Length == input.Length ||
(this.Length != null && (this.Length != null &&
this.Length.Equals(input.Length)) this.Length.Equals(input.Length))
) && ) &&
( (
this.Width == input.Width || this.Width == input.Width ||
(this.Width != null && (this.Width != null &&
this.Width.Equals(input.Width)) this.Width.Equals(input.Width))
) && ) &&
( (
this.IsTug == input.IsTug || this.IsTug == input.IsTug ||
this.IsTug.Equals(input.IsTug) this.IsTug.Equals(input.IsTug)
) && ) &&
( (
this.BollardPull == input.BollardPull || this.BollardPull == input.BollardPull ||
(this.BollardPull != null && (this.BollardPull != null &&
this.BollardPull.Equals(input.BollardPull)) this.BollardPull.Equals(input.BollardPull))
) && ) &&
( (
this.Eni == input.Eni || this.Eni == input.Eni ||
(this.Eni != null && (this.Eni != null &&
this.Eni.Equals(input.Eni)) this.Eni.Equals(input.Eni))
) && ) &&
( (
this.Created == input.Created || this.Created == input.Created ||
(this.Created != null && (this.Created != null &&
this.Created.Equals(input.Created)) this.Created.Equals(input.Created))
) && ) &&
( (
this.Modified == input.Modified || this.Modified == input.Modified ||
(this.Modified != null && (this.Modified != null &&
this.Modified.Equals(input.Modified)) this.Modified.Equals(input.Modified))
) && ) &&
( (
this.Deleted == input.Deleted || this.Deleted == input.Deleted ||
this.Deleted.Equals(input.Deleted) this.Deleted.Equals(input.Deleted)
@ -8467,144 +8477,144 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Id == input.Id || this.Id == input.Id ||
this.Id.Equals(input.Id) this.Id.Equals(input.Id)
) && ) &&
( (
this.ShipId == input.ShipId || this.ShipId == input.ShipId ||
this.ShipId.Equals(input.ShipId) this.ShipId.Equals(input.ShipId)
) && ) &&
( (
this.Type == input.Type || this.Type == input.Type ||
this.Type.Equals(input.Type) this.Type.Equals(input.Type)
) && ) &&
( (
this.Eta == input.Eta || this.Eta == input.Eta ||
(this.Eta != null && (this.Eta != null &&
this.Eta.Equals(input.Eta)) this.Eta.Equals(input.Eta))
) && ) &&
( (
this.Voyage == input.Voyage || this.Voyage == input.Voyage ||
(this.Voyage != null && (this.Voyage != null &&
this.Voyage.Equals(input.Voyage)) this.Voyage.Equals(input.Voyage))
) && ) &&
( (
this.Etd == input.Etd || this.Etd == input.Etd ||
(this.Etd != null && (this.Etd != null &&
this.Etd.Equals(input.Etd)) this.Etd.Equals(input.Etd))
) && ) &&
( (
this.ArrivalBerthId == input.ArrivalBerthId || this.ArrivalBerthId == input.ArrivalBerthId ||
(this.ArrivalBerthId != null && (this.ArrivalBerthId != null &&
this.ArrivalBerthId.Equals(input.ArrivalBerthId)) this.ArrivalBerthId.Equals(input.ArrivalBerthId))
) && ) &&
( (
this.DepartureBerthId == input.DepartureBerthId || this.DepartureBerthId == input.DepartureBerthId ||
(this.DepartureBerthId != null && (this.DepartureBerthId != null &&
this.DepartureBerthId.Equals(input.DepartureBerthId)) this.DepartureBerthId.Equals(input.DepartureBerthId))
) && ) &&
( (
this.TugRequired == input.TugRequired || this.TugRequired == input.TugRequired ||
(this.TugRequired != null && (this.TugRequired != null &&
this.TugRequired.Equals(input.TugRequired)) this.TugRequired.Equals(input.TugRequired))
) && ) &&
( (
this.PilotRequired == input.PilotRequired || this.PilotRequired == input.PilotRequired ||
(this.PilotRequired != null && (this.PilotRequired != null &&
this.PilotRequired.Equals(input.PilotRequired)) this.PilotRequired.Equals(input.PilotRequired))
) && ) &&
( (
this.Flags == input.Flags || this.Flags == input.Flags ||
(this.Flags != null && (this.Flags != null &&
this.Flags.Equals(input.Flags)) this.Flags.Equals(input.Flags))
) && ) &&
( (
this.PierSide == input.PierSide || this.PierSide == input.PierSide ||
(this.PierSide != null && (this.PierSide != null &&
this.PierSide.Equals(input.PierSide)) this.PierSide.Equals(input.PierSide))
) && ) &&
( (
this.Bunkering == input.Bunkering || this.Bunkering == input.Bunkering ||
(this.Bunkering != null && (this.Bunkering != null &&
this.Bunkering.Equals(input.Bunkering)) this.Bunkering.Equals(input.Bunkering))
) && ) &&
( (
this.ReplenishingTerminal == input.ReplenishingTerminal || this.ReplenishingTerminal == input.ReplenishingTerminal ||
(this.ReplenishingTerminal != null && (this.ReplenishingTerminal != null &&
this.ReplenishingTerminal.Equals(input.ReplenishingTerminal)) this.ReplenishingTerminal.Equals(input.ReplenishingTerminal))
) && ) &&
( (
this.ReplenishingLock == input.ReplenishingLock || this.ReplenishingLock == input.ReplenishingLock ||
(this.ReplenishingLock != null && (this.ReplenishingLock != null &&
this.ReplenishingLock.Equals(input.ReplenishingLock)) this.ReplenishingLock.Equals(input.ReplenishingLock))
) && ) &&
( (
this.Draft == input.Draft || this.Draft == input.Draft ||
(this.Draft != null && (this.Draft != null &&
this.Draft.Equals(input.Draft)) this.Draft.Equals(input.Draft))
) && ) &&
( (
this.TidalWindowFrom == input.TidalWindowFrom || this.TidalWindowFrom == input.TidalWindowFrom ||
(this.TidalWindowFrom != null && (this.TidalWindowFrom != null &&
this.TidalWindowFrom.Equals(input.TidalWindowFrom)) this.TidalWindowFrom.Equals(input.TidalWindowFrom))
) && ) &&
( (
this.TidalWindowTo == input.TidalWindowTo || this.TidalWindowTo == input.TidalWindowTo ||
(this.TidalWindowTo != null && (this.TidalWindowTo != null &&
this.TidalWindowTo.Equals(input.TidalWindowTo)) this.TidalWindowTo.Equals(input.TidalWindowTo))
) && ) &&
( (
this.RainSensitiveCargo == input.RainSensitiveCargo || this.RainSensitiveCargo == input.RainSensitiveCargo ||
(this.RainSensitiveCargo != null && (this.RainSensitiveCargo != null &&
this.RainSensitiveCargo.Equals(input.RainSensitiveCargo)) this.RainSensitiveCargo.Equals(input.RainSensitiveCargo))
) && ) &&
( (
this.RecommendedTugs == input.RecommendedTugs || this.RecommendedTugs == input.RecommendedTugs ||
(this.RecommendedTugs != null && (this.RecommendedTugs != null &&
this.RecommendedTugs.Equals(input.RecommendedTugs)) this.RecommendedTugs.Equals(input.RecommendedTugs))
) && ) &&
( (
this.Anchored == input.Anchored || this.Anchored == input.Anchored ||
(this.Anchored != null && (this.Anchored != null &&
this.Anchored.Equals(input.Anchored)) this.Anchored.Equals(input.Anchored))
) && ) &&
( (
this.MooredLock == input.MooredLock || this.MooredLock == input.MooredLock ||
(this.MooredLock != null && (this.MooredLock != null &&
this.MooredLock.Equals(input.MooredLock)) this.MooredLock.Equals(input.MooredLock))
) && ) &&
( (
this.Canceled == input.Canceled || this.Canceled == input.Canceled ||
(this.Canceled != null && (this.Canceled != null &&
this.Canceled.Equals(input.Canceled)) this.Canceled.Equals(input.Canceled))
) && ) &&
( (
this.Evaluation == input.Evaluation || this.Evaluation == input.Evaluation ||
this.Evaluation.Equals(input.Evaluation) this.Evaluation.Equals(input.Evaluation)
) && ) &&
( (
this.EvaluationMessage == input.EvaluationMessage || this.EvaluationMessage == input.EvaluationMessage ||
(this.EvaluationMessage != null && (this.EvaluationMessage != null &&
this.EvaluationMessage.Equals(input.EvaluationMessage)) this.EvaluationMessage.Equals(input.EvaluationMessage))
) && ) &&
( (
this.TimeRefPoint == input.TimeRefPoint || this.TimeRefPoint == input.TimeRefPoint ||
(this.TimeRefPoint != null && (this.TimeRefPoint != null &&
this.TimeRefPoint.Equals(input.TimeRefPoint)) this.TimeRefPoint.Equals(input.TimeRefPoint))
) && ) &&
( (
this.Participants == input.Participants || this.Participants == input.Participants ||
this.Participants != null && this.Participants != null &&
input.Participants != null && input.Participants != null &&
this.Participants.SequenceEqual(input.Participants) this.Participants.SequenceEqual(input.Participants)
) && ) &&
( (
this.Created == input.Created || this.Created == input.Created ||
(this.Created != null && (this.Created != null &&
this.Created.Equals(input.Created)) this.Created.Equals(input.Created))
) && ) &&
( (
this.Modified == input.Modified || this.Modified == input.Modified ||
(this.Modified != null && (this.Modified != null &&
@ -9060,113 +9070,113 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Id == input.Id || this.Id == input.Id ||
this.Id.Equals(input.Id) this.Id.Equals(input.Id)
) && ) &&
( (
this.EtaBerth == input.EtaBerth || this.EtaBerth == input.EtaBerth ||
(this.EtaBerth != null && (this.EtaBerth != null &&
this.EtaBerth.Equals(input.EtaBerth)) this.EtaBerth.Equals(input.EtaBerth))
) && ) &&
( (
this.EtaBerthFixed == input.EtaBerthFixed || this.EtaBerthFixed == input.EtaBerthFixed ||
(this.EtaBerthFixed != null && (this.EtaBerthFixed != null &&
this.EtaBerthFixed.Equals(input.EtaBerthFixed)) this.EtaBerthFixed.Equals(input.EtaBerthFixed))
) && ) &&
( (
this.EtdBerth == input.EtdBerth || this.EtdBerth == input.EtdBerth ||
(this.EtdBerth != null && (this.EtdBerth != null &&
this.EtdBerth.Equals(input.EtdBerth)) this.EtdBerth.Equals(input.EtdBerth))
) && ) &&
( (
this.EtdBerthFixed == input.EtdBerthFixed || this.EtdBerthFixed == input.EtdBerthFixed ||
(this.EtdBerthFixed != null && (this.EtdBerthFixed != null &&
this.EtdBerthFixed.Equals(input.EtdBerthFixed)) this.EtdBerthFixed.Equals(input.EtdBerthFixed))
) && ) &&
( (
this.LockTime == input.LockTime || this.LockTime == input.LockTime ||
(this.LockTime != null && (this.LockTime != null &&
this.LockTime.Equals(input.LockTime)) this.LockTime.Equals(input.LockTime))
) && ) &&
( (
this.LockTimeFixed == input.LockTimeFixed || this.LockTimeFixed == input.LockTimeFixed ||
(this.LockTimeFixed != null && (this.LockTimeFixed != null &&
this.LockTimeFixed.Equals(input.LockTimeFixed)) this.LockTimeFixed.Equals(input.LockTimeFixed))
) && ) &&
( (
this.ZoneEntry == input.ZoneEntry || this.ZoneEntry == input.ZoneEntry ||
(this.ZoneEntry != null && (this.ZoneEntry != null &&
this.ZoneEntry.Equals(input.ZoneEntry)) this.ZoneEntry.Equals(input.ZoneEntry))
) && ) &&
( (
this.ZoneEntryFixed == input.ZoneEntryFixed || this.ZoneEntryFixed == input.ZoneEntryFixed ||
(this.ZoneEntryFixed != null && (this.ZoneEntryFixed != null &&
this.ZoneEntryFixed.Equals(input.ZoneEntryFixed)) this.ZoneEntryFixed.Equals(input.ZoneEntryFixed))
) && ) &&
( (
this.OperationsStart == input.OperationsStart || this.OperationsStart == input.OperationsStart ||
(this.OperationsStart != null && (this.OperationsStart != null &&
this.OperationsStart.Equals(input.OperationsStart)) this.OperationsStart.Equals(input.OperationsStart))
) && ) &&
( (
this.OperationsEnd == input.OperationsEnd || this.OperationsEnd == input.OperationsEnd ||
(this.OperationsEnd != null && (this.OperationsEnd != null &&
this.OperationsEnd.Equals(input.OperationsEnd)) this.OperationsEnd.Equals(input.OperationsEnd))
) && ) &&
( (
this.Remarks == input.Remarks || this.Remarks == input.Remarks ||
(this.Remarks != null && (this.Remarks != null &&
this.Remarks.Equals(input.Remarks)) this.Remarks.Equals(input.Remarks))
) && ) &&
( (
this.ShipcallId == input.ShipcallId || this.ShipcallId == input.ShipcallId ||
this.ShipcallId.Equals(input.ShipcallId) this.ShipcallId.Equals(input.ShipcallId)
) && ) &&
( (
this.ParticipantId == input.ParticipantId || this.ParticipantId == input.ParticipantId ||
this.ParticipantId.Equals(input.ParticipantId) this.ParticipantId.Equals(input.ParticipantId)
) && ) &&
( (
this.BerthId == input.BerthId || this.BerthId == input.BerthId ||
(this.BerthId != null && (this.BerthId != null &&
this.BerthId.Equals(input.BerthId)) this.BerthId.Equals(input.BerthId))
) && ) &&
( (
this.BerthInfo == input.BerthInfo || this.BerthInfo == input.BerthInfo ||
(this.BerthInfo != null && (this.BerthInfo != null &&
this.BerthInfo.Equals(input.BerthInfo)) this.BerthInfo.Equals(input.BerthInfo))
) && ) &&
( (
this.PierSide == input.PierSide || this.PierSide == input.PierSide ||
(this.PierSide != null && (this.PierSide != null &&
this.PierSide.Equals(input.PierSide)) this.PierSide.Equals(input.PierSide))
) && ) &&
( (
this.ParticipantType == input.ParticipantType || this.ParticipantType == input.ParticipantType ||
this.ParticipantType.Equals(input.ParticipantType) this.ParticipantType.Equals(input.ParticipantType)
) && ) &&
( (
this.Ata == input.Ata || this.Ata == input.Ata ||
(this.Ata != null && (this.Ata != null &&
this.Ata.Equals(input.Ata)) this.Ata.Equals(input.Ata))
) && ) &&
( (
this.Atd == input.Atd || this.Atd == input.Atd ||
(this.Atd != null && (this.Atd != null &&
this.Atd.Equals(input.Atd)) this.Atd.Equals(input.Atd))
) && ) &&
( (
this.IntervalEnd == input.IntervalEnd || this.IntervalEnd == input.IntervalEnd ||
(this.IntervalEnd != null && (this.IntervalEnd != null &&
this.IntervalEnd.Equals(input.IntervalEnd)) this.IntervalEnd.Equals(input.IntervalEnd))
) && ) &&
( (
this.Created == input.Created || this.Created == input.Created ||
(this.Created != null && (this.Created != null &&
this.Created.Equals(input.Created)) this.Created.Equals(input.Created))
) && ) &&
( (
this.Modified == input.Modified || this.Modified == input.Modified ||
(this.Modified != null && (this.Modified != null &&
@ -9242,13 +9252,9 @@ namespace BreCalClient.misc.Model
hashCode = (hashCode * 59) + this.PierSide.GetHashCode(); hashCode = (hashCode * 59) + this.PierSide.GetHashCode();
} }
hashCode = (hashCode * 59) + this.ParticipantType.GetHashCode(); hashCode = (hashCode * 59) + this.ParticipantType.GetHashCode();
if (this.Ata != null) if (this.AtaAtd != null)
{ {
hashCode = (hashCode * 59) + this.Ata.GetHashCode(); hashCode = (hashCode * 59) + this.AtaAtd.GetHashCode();
}
if (this.Atd != null)
{
hashCode = (hashCode * 59) + this.Atd.GetHashCode();
} }
if (this.IntervalEnd != null) if (this.IntervalEnd != null)
{ {
@ -9405,36 +9411,36 @@ namespace BreCalClient.misc.Model
{ {
return false; return false;
} }
return return
( (
this.Id == input.Id || this.Id == input.Id ||
this.Id.Equals(input.Id) this.Id.Equals(input.Id)
) && ) &&
( (
this.OldPassword == input.OldPassword || this.OldPassword == input.OldPassword ||
(this.OldPassword != null && (this.OldPassword != null &&
this.OldPassword.Equals(input.OldPassword)) this.OldPassword.Equals(input.OldPassword))
) && ) &&
( (
this.NewPassword == input.NewPassword || this.NewPassword == input.NewPassword ||
(this.NewPassword != null && (this.NewPassword != null &&
this.NewPassword.Equals(input.NewPassword)) this.NewPassword.Equals(input.NewPassword))
) && ) &&
( (
this.FirstName == input.FirstName || this.FirstName == input.FirstName ||
(this.FirstName != null && (this.FirstName != null &&
this.FirstName.Equals(input.FirstName)) this.FirstName.Equals(input.FirstName))
) && ) &&
( (
this.LastName == input.LastName || this.LastName == input.LastName ||
(this.LastName != null && (this.LastName != null &&
this.LastName.Equals(input.LastName)) this.LastName.Equals(input.LastName))
) && ) &&
( (
this.UserPhone == input.UserPhone || this.UserPhone == input.UserPhone ||
(this.UserPhone != null && (this.UserPhone != null &&
this.UserPhone.Equals(input.UserPhone)) this.UserPhone.Equals(input.UserPhone))
) && ) &&
( (
this.UserEmail == input.UserEmail || this.UserEmail == input.UserEmail ||
(this.UserEmail != null && (this.UserEmail != null &&

View File

@ -435,6 +435,13 @@ paths:
tags: tags:
- static - static
operationId: historyGet operationId: historyGet
parameters:
- name: shipcall_id
in: query
required: true
description: '**Id of ship call**. *Example: 52*. Id given in ship call list'
schema:
$ref: '#/components/schemas/shipcallId'
responses: responses:
'200': '200':
description: list of history entries description: list of history entries

View File

@ -34,6 +34,8 @@
<None Remove="Resources\delete2.png" /> <None Remove="Resources\delete2.png" />
<None Remove="Resources\edit.png" /> <None Remove="Resources\edit.png" />
<None Remove="Resources\emergency_stop_button.png" /> <None Remove="Resources\emergency_stop_button.png" />
<None Remove="Resources\lock.png" />
<None Remove="Resources\lock_open.png" />
<None Remove="Resources\logo_bremen_calling.png" /> <None Remove="Resources\logo_bremen_calling.png" />
<None Remove="Resources\ship2.png" /> <None Remove="Resources\ship2.png" />
<None Remove="Resources\sign_warning.png" /> <None Remove="Resources\sign_warning.png" />
@ -87,6 +89,8 @@
<Resource Include="Resources\delete2.png" /> <Resource Include="Resources\delete2.png" />
<Resource Include="Resources\edit.png" /> <Resource Include="Resources\edit.png" />
<Resource Include="Resources\emergency_stop_button.png" /> <Resource Include="Resources\emergency_stop_button.png" />
<Resource Include="Resources\lock.png" />
<Resource Include="Resources\lock_open.png" />
<Resource Include="Resources\logo_bremen_calling.png" /> <Resource Include="Resources\logo_bremen_calling.png" />
<Resource Include="Resources\ship2.png" /> <Resource Include="Resources\ship2.png" />
<Resource Include="Resources\sign_warning.png" /> <Resource Include="Resources\sign_warning.png" />
@ -106,11 +110,11 @@
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<PackageReference Include="Extended.Wpf.Toolkit" Version="4.5.1" /> <PackageReference Include="Extended.Wpf.Toolkit" Version="4.6.0" />
<PackageReference Include="JsonSubTypes" Version="2.0.1" /> <PackageReference Include="JsonSubTypes" Version="2.0.1" />
<PackageReference Include="log4net" Version="2.0.15" /> <PackageReference Include="log4net" Version="2.0.17" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.3" /> <PackageReference Include="Newtonsoft.Json" Version="13.0.3" />
<PackageReference Include="Polly" Version="8.2.0" /> <PackageReference Include="Polly" Version="8.3.1" />
<PackageReference Include="RestSharp" Version="110.2.0" /> <PackageReference Include="RestSharp" Version="110.2.0" />
</ItemGroup> </ItemGroup>

View File

@ -1,12 +1,12 @@
extensions: designer.cs generated.cs extensions: designer.cs generated.cs
extensions: .cs .cpp .h extensions: .cs .cpp .h
// Copyright (c) 2023 schick Informatik // Copyright (c) 2024- schick Informatik
// Description: // Description:
// //
extensions: .aspx .ascx extensions: .aspx .ascx
<%-- <%--
Copyright (c) 2023 schick Informatik Copyright (c) 2024- schick Informatik
--%> --%>
extensions: .vb extensions: .vb
'Sample license text. 'Sample license text.

View File

@ -44,9 +44,9 @@
</Grid> </Grid>
<Label Content="ETA" x:Name="labelETA" Grid.Column="0" Grid.Row="1" HorizontalContentAlignment="Right" FontWeight="Bold"/> <Label Content="ETA" x:Name="labelETA" Grid.Column="0" Grid.Row="1" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<xctk:DateTimePicker x:Name="datePickerETA" Grid.Column="1" Grid.Row="1" Margin="2" Format="Custom" FormatString="dd.MM. yyyy HH:mm"/> <xctk:DateTimePicker x:Name="datePickerETA" Grid.Column="1" Grid.Row="1" Margin="2" Format="Custom" FormatString="dd.MM. yyyy HH:mm" ValueChanged="datePickerETA_ValueChanged"/>
<Label Content="{x:Static p:Resources.textBerth}" Grid.Column="0" Grid.Row="2" HorizontalContentAlignment="Right" FontWeight="Bold"/> <Label Content="{x:Static p:Resources.textBerth}" Grid.Column="0" Grid.Row="2" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<ComboBox Name="comboBoxArrivalBerth" Grid.Column="1" Grid.Row="2" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id"> <ComboBox Name="comboBoxArrivalBerth" Grid.Column="1" Grid.Row="2" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id" SelectionChanged="comboBoxArrivalBerth_SelectionChanged">
</ComboBox> </ComboBox>
<Label Content="{x:Static p:Resources.textPierside}" Grid.Column="0" Grid.Row="3" HorizontalContentAlignment="Right" /> <Label Content="{x:Static p:Resources.textPierside}" Grid.Column="0" Grid.Row="3" HorizontalContentAlignment="Right" />
@ -61,8 +61,8 @@
</ComboBox> </ComboBox>
<Label Content="{x:Static p:Resources.textBerthRemarks}" Grid.Column="0" Grid.Row="4" HorizontalContentAlignment="Right" /> <Label Content="{x:Static p:Resources.textBerthRemarks}" Grid.Column="0" Grid.Row="4" HorizontalContentAlignment="Right" />
<TextBox x:Name="textBoxBerthRemarks" Grid.Column="1" Grid.Row="4" Margin="2" Grid.RowSpan="2" VerticalContentAlignment="Top" AcceptsReturn="True" MaxLength="512"/> <TextBox x:Name="textBoxBerthRemarks" Grid.Column="1" Grid.Row="4" Margin="2" Grid.RowSpan="2" VerticalContentAlignment="Top" AcceptsReturn="True" MaxLength="512"/>
<Label Content="{x:Static p:Resources.textDraft}" Grid.Column="0" Grid.Row="6" HorizontalContentAlignment="Right" /> <Label Content="{x:Static p:Resources.textDraft}" Grid.Column="0" Grid.Row="6" HorizontalContentAlignment="Right" FontWeight="Bold" />
<xctk:DoubleUpDown x:Name="doubleUpDownDraft" Grid.Column="1" Grid.Row="6" Margin="2" FormatString="N2" Minimum="0" Maximum="50" MaxLength="5"/> <xctk:DoubleUpDown x:Name="doubleUpDownDraft" Grid.Column="1" Grid.Row="6" Margin="2" FormatString="N2" Minimum="0" Maximum="50" MaxLength="5" ValueChanged="doubleUpDownDraft_ValueChanged"/>
<Label Content="{x:Static p:Resources.textTidalWindow}" FontWeight="DemiBold" Grid.Column="0" Grid.Row="7" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textTidalWindow}" FontWeight="DemiBold" Grid.Column="0" Grid.Row="7" HorizontalContentAlignment="Right"/>
<Label Content="{x:Static p:Resources.textFrom}" Grid.Column="0" Grid.Row="8" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textFrom}" Grid.Column="0" Grid.Row="8" HorizontalContentAlignment="Right"/>
<Label Content="{x:Static p:Resources.textTo}" Grid.Column="0" Grid.Row="9" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textTo}" Grid.Column="0" Grid.Row="9" HorizontalContentAlignment="Right"/>

View File

@ -14,6 +14,12 @@ namespace BreCalClient
/// </summary> /// </summary>
public partial class EditTimesAgencyIncomingControl : Window, IEditTimesControl public partial class EditTimesAgencyIncomingControl : Window, IEditTimesControl
{ {
#region Fields
bool _editing = false;
#endregion
#region Construction #region Construction
public EditTimesAgencyIncomingControl() public EditTimesAgencyIncomingControl()
@ -55,10 +61,10 @@ namespace BreCalClient
allowBSMD = p.IsFlagSet(ParticipantFlag.ALLOW_BSMD); allowBSMD = p.IsFlagSet(ParticipantFlag.ALLOW_BSMD);
} }
bool enableControls = (this.Times.ParticipantId == App.Participant.Id) || _editing = (this.Times.ParticipantId == App.Participant.Id) ||
(App.Participant.IsTypeFlagSet(ParticipantType.BSMD) && allowBSMD); (App.Participant.IsTypeFlagSet(ParticipantType.BSMD) && allowBSMD);
this.EnableControls(enableControls); this.EnableControls();
} }
@ -240,37 +246,50 @@ namespace BreCalClient
} }
} }
private void EnableControls(bool isEnabled) private void EnableControls()
{ {
this.datePickerETA.IsEnabled = isEnabled; this.datePickerETA.IsEnabled = _editing;
this.comboBoxArrivalBerth.IsEnabled = isEnabled; this.comboBoxArrivalBerth.IsEnabled = _editing;
this.comboBoxPierside.IsEnabled = isEnabled; this.comboBoxPierside.IsEnabled = _editing;
this.textBoxBerthRemarks.IsEnabled = isEnabled; this.textBoxBerthRemarks.IsEnabled = _editing;
this.doubleUpDownDraft.IsEnabled = isEnabled; this.doubleUpDownDraft.IsEnabled = _editing;
this.datePickerTidalWindowFrom.IsEnabled = isEnabled; this.datePickerTidalWindowFrom.IsEnabled = _editing;
this.datePickerTidalWindowTo.IsEnabled = isEnabled; this.datePickerTidalWindowTo.IsEnabled = _editing;
this.checkBoxCanceled.IsEnabled = isEnabled; this.checkBoxCanceled.IsEnabled = _editing;
this.checkBoxAnchored.IsEnabled = isEnabled; this.checkBoxAnchored.IsEnabled = _editing;
this.comboBoxTug.IsEnabled = isEnabled; this.comboBoxTug.IsEnabled = _editing;
this.integerUpDownRecommendedTugs.IsEnabled = isEnabled; this.integerUpDownRecommendedTugs.IsEnabled = _editing;
this.comboBoxPilot.IsEnabled = isEnabled; this.comboBoxPilot.IsEnabled = _editing;
this.comboBoxMooring.IsEnabled = isEnabled; this.comboBoxMooring.IsEnabled = _editing;
this.checkBoxMooredLock.IsEnabled = isEnabled; this.checkBoxMooredLock.IsEnabled = _editing;
this.comboBoxTerminal.IsEnabled = isEnabled; this.comboBoxTerminal.IsEnabled = _editing;
this.checkBoxBunkering.IsEnabled = isEnabled; this.checkBoxBunkering.IsEnabled = _editing;
this.checkBoxReplenishingTerminal.IsEnabled = isEnabled; this.checkBoxReplenishingTerminal.IsEnabled = _editing;
this.checkBoxReplenishingLock.IsEnabled = isEnabled; this.checkBoxReplenishingLock.IsEnabled = _editing;
this.textBoxRemarks.IsEnabled = isEnabled; this.textBoxRemarks.IsEnabled = _editing;
this.buttonOK.IsEnabled = isEnabled; CheckOKButton();
}
private bool RequiredFieldsSet()
{
bool areSet = this.datePickerETA.Value.HasValue &&
this.doubleUpDownDraft.Value.HasValue &&
this.comboBoxArrivalBerth.SelectedIndex >= 0;
return areSet;
}
private void CheckOKButton()
{
this.buttonOK.IsEnabled = _editing && RequiredFieldsSet();
} }
#endregion #endregion
#region context menu handlers #region event handlers
private void contextMenuItemArrivalBerth_Click(object sender, RoutedEventArgs e) private void contextMenuItemArrivalBerth_Click(object sender, RoutedEventArgs e)
{ {
@ -305,6 +324,21 @@ namespace BreCalClient
private void contextMenuItemClearPierside_Click(object sender, RoutedEventArgs e) private void contextMenuItemClearPierside_Click(object sender, RoutedEventArgs e)
{ {
this.comboBoxPierside.SelectedIndex = -1; this.comboBoxPierside.SelectedIndex = -1;
}
private void doubleUpDownDraft_ValueChanged(object sender, RoutedPropertyChangedEventArgs<object> e)
{
this.CheckOKButton();
}
private void datePickerETA_ValueChanged(object sender, RoutedPropertyChangedEventArgs<object> e)
{
this.CheckOKButton();
}
private void comboBoxArrivalBerth_SelectionChanged(object sender, System.Windows.Controls.SelectionChangedEventArgs e)
{
this.CheckOKButton();
} }
#endregion #endregion

View File

@ -40,10 +40,9 @@
</Grid> </Grid>
<Label Content="ETD" x:Name="labelETD" Grid.Column="0" Grid.Row="1" HorizontalContentAlignment="Right" FontWeight="Bold"/> <Label Content="ETD" x:Name="labelETD" Grid.Column="0" Grid.Row="1" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<xctk:DateTimePicker x:Name="datePickerETD" Grid.Column="1" Grid.Row="1" Margin="2" Format="Custom" FormatString="dd.MM. yyyy HH:mm"/> <xctk:DateTimePicker x:Name="datePickerETD" Grid.Column="1" Grid.Row="1" Margin="2" Format="Custom" FormatString="dd.MM. yyyy HH:mm" ValueChanged="datePickerETD_ValueChanged"/>
<Label Content="{x:Static p:Resources.textBerth}" Grid.Column="0" Grid.Row="2" HorizontalContentAlignment="Right" FontWeight="Bold"/> <Label Content="{x:Static p:Resources.textBerth}" Grid.Column="0" Grid.Row="2" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<ComboBox Name="comboBoxDepartureBerth" Grid.Column="1" Grid.Row="2" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id"> <ComboBox Name="comboBoxDepartureBerth" Grid.Column="1" Grid.Row="2" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id" SelectionChanged="comboBoxDepartureBerth_SelectionChanged" />
</ComboBox>
<Label Content="{x:Static p:Resources.textPierside}" Grid.Column="0" Grid.Row="3" HorizontalContentAlignment="Right" /> <Label Content="{x:Static p:Resources.textPierside}" Grid.Column="0" Grid.Row="3" HorizontalContentAlignment="Right" />
<ComboBox x:Name="comboBoxPierside" Grid.Column="1" Grid.Row="3" Margin="2" > <ComboBox x:Name="comboBoxPierside" Grid.Column="1" Grid.Row="3" Margin="2" >
<ComboBoxItem Content="{x:Static p:Resources.textPort}" /> <ComboBoxItem Content="{x:Static p:Resources.textPort}" />
@ -56,8 +55,8 @@
</ComboBox> </ComboBox>
<Label Content="{x:Static p:Resources.textBerthRemarks}" Grid.Column="0" Grid.Row="4" HorizontalContentAlignment="Right" /> <Label Content="{x:Static p:Resources.textBerthRemarks}" Grid.Column="0" Grid.Row="4" HorizontalContentAlignment="Right" />
<TextBox x:Name="textBoxBerthRemarks" Grid.Column="1" Grid.Row="4" Margin="2" Grid.RowSpan="2" VerticalContentAlignment="Top" AcceptsReturn="True" MaxLength="512"/> <TextBox x:Name="textBoxBerthRemarks" Grid.Column="1" Grid.Row="4" Margin="2" Grid.RowSpan="2" VerticalContentAlignment="Top" AcceptsReturn="True" MaxLength="512"/>
<Label Content="{x:Static p:Resources.textDraft}" Grid.Column="0" Grid.Row="6" HorizontalContentAlignment="Right" /> <Label Content="{x:Static p:Resources.textDraft}" Grid.Column="0" Grid.Row="6" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<xctk:DoubleUpDown x:Name="doubleUpDownDraft" Grid.Column="1" Grid.Row="6" Margin="2" FormatString="N2" Minimum="0" Maximum="50" MaxLength="5"/> <xctk:DoubleUpDown x:Name="doubleUpDownDraft" Grid.Column="1" Grid.Row="6" Margin="2" FormatString="N2" Minimum="0" Maximum="50" MaxLength="5" ValueChanged="doubleUpDownDraft_ValueChanged"/>
<Label Content="{x:Static p:Resources.textTidalWindow}" FontWeight="DemiBold" Grid.Column="0" Grid.Row="7" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textTidalWindow}" FontWeight="DemiBold" Grid.Column="0" Grid.Row="7" HorizontalContentAlignment="Right"/>
<Label Content="{x:Static p:Resources.textFrom}" Grid.Column="0" Grid.Row="8" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textFrom}" Grid.Column="0" Grid.Row="8" HorizontalContentAlignment="Right"/>
<Label Content="{x:Static p:Resources.textTo}" Grid.Column="0" Grid.Row="9" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textTo}" Grid.Column="0" Grid.Row="9" HorizontalContentAlignment="Right"/>

View File

@ -15,6 +15,12 @@ namespace BreCalClient
public partial class EditTimesAgencyOutgoingControl : Window, IEditTimesControl public partial class EditTimesAgencyOutgoingControl : Window, IEditTimesControl
{ {
#region Fields
bool _editing = false;
#endregion
#region Construction #region Construction
public EditTimesAgencyOutgoingControl() public EditTimesAgencyOutgoingControl()
@ -56,10 +62,10 @@ namespace BreCalClient
allowBSMD = p.IsFlagSet(ParticipantFlag.ALLOW_BSMD); allowBSMD = p.IsFlagSet(ParticipantFlag.ALLOW_BSMD);
} }
bool enableControls = (this.Times.ParticipantId == App.Participant.Id) || _editing = (this.Times.ParticipantId == App.Participant.Id) ||
(App.Participant.IsTypeFlagSet(ParticipantType.BSMD) && allowBSMD); (App.Participant.IsTypeFlagSet(ParticipantType.BSMD) && allowBSMD);
this.EnableControls(enableControls); this.EnableControls();
} }
@ -232,33 +238,46 @@ namespace BreCalClient
} }
} }
private void EnableControls(bool isEnabled) private void EnableControls()
{ {
this.datePickerETD.IsEnabled = isEnabled; this.datePickerETD.IsEnabled = _editing;
this.comboBoxDepartureBerth.IsEnabled = isEnabled; this.comboBoxDepartureBerth.IsEnabled = _editing;
this.comboBoxPierside.IsEnabled = isEnabled; this.comboBoxPierside.IsEnabled = _editing;
this.textBoxBerthRemarks.IsEnabled = isEnabled; this.textBoxBerthRemarks.IsEnabled = _editing;
this.doubleUpDownDraft.IsEnabled = isEnabled; this.doubleUpDownDraft.IsEnabled = _editing;
this.datePickerTidalWindowFrom.IsEnabled = isEnabled; this.datePickerTidalWindowFrom.IsEnabled = _editing;
this.datePickerTidalWindowTo.IsEnabled = isEnabled; this.datePickerTidalWindowTo.IsEnabled = _editing;
this.checkBoxCanceled.IsEnabled = isEnabled; this.checkBoxCanceled.IsEnabled = _editing;
this.comboBoxTug.IsEnabled = isEnabled; this.comboBoxTug.IsEnabled = _editing;
this.integerUpDownRecommendedTugs.IsEnabled = isEnabled; this.integerUpDownRecommendedTugs.IsEnabled = _editing;
this.comboBoxPilot.IsEnabled = isEnabled; this.comboBoxPilot.IsEnabled = _editing;
this.comboBoxMooring.IsEnabled = isEnabled; this.comboBoxMooring.IsEnabled = _editing;
this.checkBoxMooredLock.IsEnabled = isEnabled; this.checkBoxMooredLock.IsEnabled = _editing;
this.comboBoxTerminal.IsEnabled = isEnabled; this.comboBoxTerminal.IsEnabled = _editing;
this.checkBoxRainsensitiveCargo.IsEnabled = isEnabled; this.checkBoxRainsensitiveCargo.IsEnabled = _editing;
this.textBoxRemarks.IsEnabled = isEnabled; this.textBoxRemarks.IsEnabled = _editing;
this.buttonOK.IsEnabled = isEnabled; CheckOKButton();
}
private bool RequiredFieldsSet()
{
bool areSet = this.datePickerETD.Value.HasValue &&
this.doubleUpDownDraft.Value.HasValue &&
this.comboBoxDepartureBerth.SelectedIndex >= 0;
return areSet;
}
private void CheckOKButton()
{
this.buttonOK.IsEnabled = _editing && RequiredFieldsSet();
} }
#endregion #endregion
#region context menu handlers #region event handlers
private void contextMenuItemClearTug_Click(object sender, RoutedEventArgs e) private void contextMenuItemClearTug_Click(object sender, RoutedEventArgs e)
{ {
@ -293,6 +312,21 @@ namespace BreCalClient
private void contextMenuItemClearPierside_Click(object sender, RoutedEventArgs e) private void contextMenuItemClearPierside_Click(object sender, RoutedEventArgs e)
{ {
this.comboBoxPierside.SelectedIndex = -1; this.comboBoxPierside.SelectedIndex = -1;
}
private void datePickerETD_ValueChanged(object sender, RoutedPropertyChangedEventArgs<object> e)
{
CheckOKButton();
}
private void comboBoxDepartureBerth_SelectionChanged(object sender, System.Windows.Controls.SelectionChangedEventArgs e)
{
CheckOKButton();
}
private void doubleUpDownDraft_ValueChanged(object sender, RoutedPropertyChangedEventArgs<object> e)
{
CheckOKButton();
} }
#endregion #endregion

View File

@ -45,7 +45,7 @@
<Image Margin="2" Grid.Column="1" Source="Resources/arrow_right_green.png" /> <Image Margin="2" Grid.Column="1" Source="Resources/arrow_right_green.png" />
</Grid> </Grid>
<Label Content="ETD" x:Name="labelETD" Grid.Column="0" Grid.Row="1" HorizontalContentAlignment="Right" FontWeight="Bold"/> <Label Content="ETD" x:Name="labelETD" Grid.Column="0" Grid.Row="1" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<xctk:DateTimePicker x:Name="datePickerETD" Grid.Column="1" Grid.Row="1" Margin="2" Format="Custom" FormatString="dd.MM. yyyy HH:mm"/> <xctk:DateTimePicker x:Name="datePickerETD" Grid.Column="1" Grid.Row="1" Margin="2" Format="Custom" FormatString="dd.MM. yyyy HH:mm" ValueChanged="datePickerETD_ValueChanged"/>
<Label Content="{x:Static p:Resources.textTerminal}" Grid.Column="0" Grid.Row="2" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textTerminal}" Grid.Column="0" Grid.Row="2" HorizontalContentAlignment="Right"/>
<ComboBox Name="comboBoxTerminal" Grid.Column="1" Grid.Row="2" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id"> <ComboBox Name="comboBoxTerminal" Grid.Column="1" Grid.Row="2" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id">
@ -57,11 +57,11 @@
</ComboBox> </ComboBox>
<Label Content="{x:Static p:Resources.textBerth}" Grid.Column="0" Grid.Row="3" HorizontalContentAlignment="Right" FontWeight="Bold"/> <Label Content="{x:Static p:Resources.textBerth}" Grid.Column="0" Grid.Row="3" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<ComboBox Name="comboBoxDepartureBerth" Grid.Column="1" Grid.Row="3" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id"> <ComboBox Name="comboBoxDepartureBerth" Grid.Column="1" Grid.Row="3" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id" SelectionChanged="comboBoxDepartureBerth_SelectionChanged">
</ComboBox> </ComboBox>
<Label Content="{x:Static p:Resources.textDraft}" Grid.Column="0" Grid.Row="4" HorizontalContentAlignment="Right" /> <Label Content="{x:Static p:Resources.textDraft}" Grid.Column="0" Grid.Row="4" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<xctk:DoubleUpDown x:Name="doubleUpDownDraft" Grid.Column="1" Grid.Row="4" Margin="2" FormatString="N2" Minimum="0" Maximum="50" MaxLength="5"/> <xctk:DoubleUpDown x:Name="doubleUpDownDraft" Grid.Column="1" Grid.Row="4" Margin="2" FormatString="N2" Minimum="0" Maximum="50" MaxLength="5" ValueChanged="doubleUpDownDraft_ValueChanged"/>
<Label Content="{x:Static p:Resources.textTidalWindow}" FontWeight="DemiBold" Grid.Column="0" Grid.Row="5" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textTidalWindow}" FontWeight="DemiBold" Grid.Column="0" Grid.Row="5" HorizontalContentAlignment="Right"/>
<Label Content="{x:Static p:Resources.textFrom}" Grid.Column="0" Grid.Row="6" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textFrom}" Grid.Column="0" Grid.Row="6" HorizontalContentAlignment="Right"/>
<Label Content="{x:Static p:Resources.textTo}" Grid.Column="0" Grid.Row="7" HorizontalContentAlignment="Right"/> <Label Content="{x:Static p:Resources.textTo}" Grid.Column="0" Grid.Row="7" HorizontalContentAlignment="Right"/>
@ -76,11 +76,10 @@
<Image Margin="2" Grid.Column="1" Source="Resources/arrow_right_green.png" /> <Image Margin="2" Grid.Column="1" Source="Resources/arrow_right_green.png" />
</Grid> </Grid>
<Label Content="ETA" x:Name="labelETA" Grid.Column="0" Grid.Row="9" HorizontalContentAlignment="Right" FontWeight="Bold"/> <Label Content="ETA" x:Name="labelETA" Grid.Column="0" Grid.Row="9" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<xctk:DateTimePicker x:Name="datePickerETA" Grid.Column="1" Grid.Row="9" Margin="2" Format="Custom" FormatString="dd.MM. yyyy HH:mm"/> <xctk:DateTimePicker x:Name="datePickerETA" Grid.Column="1" Grid.Row="9" Margin="2" Format="Custom" FormatString="dd.MM. yyyy HH:mm" ValueChanged="datePickerETA_ValueChanged"/>
<Label Content="{x:Static p:Resources.textBerth}" Grid.Column="0" Grid.Row="10" HorizontalContentAlignment="Right" FontWeight="Bold"/> <Label Content="{x:Static p:Resources.textBerth}" Grid.Column="0" Grid.Row="10" HorizontalContentAlignment="Right" FontWeight="Bold"/>
<ComboBox Name="comboBoxArrivalBerth" Grid.Column="1" Grid.Row="10" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id"> <ComboBox Name="comboBoxArrivalBerth" Grid.Column="1" Grid.Row="10" Margin="2" DisplayMemberPath="Name" SelectedValuePath="Id" SelectionChanged="comboBoxArrivalBerth_SelectionChanged" />
</ComboBox>
<Label Content="{x:Static p:Resources.textPierside}" Grid.Column="0" Grid.Row="11" HorizontalContentAlignment="Right" /> <Label Content="{x:Static p:Resources.textPierside}" Grid.Column="0" Grid.Row="11" HorizontalContentAlignment="Right" />
<ComboBox x:Name="comboBoxPiersideArrival" Grid.Column="1" Grid.Row="11" Margin="2" > <ComboBox x:Name="comboBoxPiersideArrival" Grid.Column="1" Grid.Row="11" Margin="2" >
<ComboBoxItem Content="{x:Static p:Resources.textPort}" /> <ComboBoxItem Content="{x:Static p:Resources.textPort}" />

View File

@ -14,6 +14,11 @@ namespace BreCalClient
/// </summary> /// </summary>
public partial class EditTimesAgencyShiftingControl : Window, IEditTimesControl public partial class EditTimesAgencyShiftingControl : Window, IEditTimesControl
{ {
#region Fields
bool _editing = false;
#endregion
#region Construction #region Construction
@ -57,10 +62,10 @@ namespace BreCalClient
allowBSMD = p.IsFlagSet(ParticipantFlag.ALLOW_BSMD); allowBSMD = p.IsFlagSet(ParticipantFlag.ALLOW_BSMD);
} }
bool enableControls = (this.Times.ParticipantId == App.Participant.Id) || _editing = (this.Times.ParticipantId == App.Participant.Id) ||
(App.Participant.IsTypeFlagSet(ParticipantType.BSMD) && allowBSMD); (App.Participant.IsTypeFlagSet(ParticipantType.BSMD) && allowBSMD);
this.EnableControls(enableControls); this.EnableControls();
} }
@ -247,35 +252,50 @@ namespace BreCalClient
} }
} }
private void EnableControls(bool isEnabled) private void EnableControls()
{ {
this.datePickerETD.IsEnabled = isEnabled; this.datePickerETD.IsEnabled = _editing;
this.comboBoxArrivalBerth.IsEnabled = isEnabled; this.comboBoxArrivalBerth.IsEnabled = _editing;
this.doubleUpDownDraft.IsEnabled = isEnabled; this.doubleUpDownDraft.IsEnabled = _editing;
this.datePickerTidalWindowFrom.IsEnabled = isEnabled; this.datePickerTidalWindowFrom.IsEnabled = _editing;
this.datePickerTidalWindowTo.IsEnabled = isEnabled; this.datePickerTidalWindowTo.IsEnabled = _editing;
this.datePickerETA.IsEnabled = isEnabled; this.datePickerETA.IsEnabled = _editing;
this.comboBoxDepartureBerth.IsEnabled = isEnabled; this.comboBoxDepartureBerth.IsEnabled = _editing;
this.comboBoxPiersideArrival.IsEnabled = isEnabled; this.comboBoxPiersideArrival.IsEnabled = _editing;
this.textBoxBerthRemarksArrival.IsEnabled = isEnabled; this.textBoxBerthRemarksArrival.IsEnabled = _editing;
this.checkBoxCanceled.IsEnabled = isEnabled; this.checkBoxCanceled.IsEnabled = _editing;
this.comboBoxTug.IsEnabled = isEnabled; this.comboBoxTug.IsEnabled = _editing;
this.integerUpDownRecommendedTugs.IsEnabled = isEnabled; this.integerUpDownRecommendedTugs.IsEnabled = _editing;
this.comboBoxPilot.IsEnabled = isEnabled; this.comboBoxPilot.IsEnabled = _editing;
this.comboBoxMooring.IsEnabled = isEnabled; this.comboBoxMooring.IsEnabled = _editing;
this.checkBoxMooredLock.IsEnabled = isEnabled; this.checkBoxMooredLock.IsEnabled = _editing;
this.comboBoxTerminal.IsEnabled = isEnabled; this.comboBoxTerminal.IsEnabled = _editing;
this.checkBoxRainsensitiveCargo.IsEnabled = isEnabled; this.checkBoxRainsensitiveCargo.IsEnabled = _editing;
this.textBoxRemarks.IsEnabled = isEnabled; this.textBoxRemarks.IsEnabled = _editing;
this.buttonOK.IsEnabled = isEnabled; CheckOKButton();
}
private bool RequiredFieldsSet()
{
bool areSet = this.datePickerETA.Value.HasValue &&
this.datePickerETD.Value.HasValue &&
this.doubleUpDownDraft.Value.HasValue &&
(this.comboBoxArrivalBerth.SelectedIndex >= 0) &&
(this.comboBoxDepartureBerth.SelectedIndex >= 0);
return areSet;
}
private void CheckOKButton()
{
this.buttonOK.IsEnabled = _editing && RequiredFieldsSet();
} }
#endregion #endregion
#region context menu handlers #region event handlers
private void contextMenuItemDepartureBerth_Click(object sender, RoutedEventArgs e) private void contextMenuItemDepartureBerth_Click(object sender, RoutedEventArgs e)
{ {
@ -316,6 +336,31 @@ namespace BreCalClient
private void contextMenuItemClearPierside_Click(object sender, RoutedEventArgs e) private void contextMenuItemClearPierside_Click(object sender, RoutedEventArgs e)
{ {
this.comboBoxPiersideArrival.SelectedIndex = -1; this.comboBoxPiersideArrival.SelectedIndex = -1;
}
private void datePickerETD_ValueChanged(object sender, RoutedPropertyChangedEventArgs<object> e)
{
CheckOKButton();
}
private void comboBoxDepartureBerth_SelectionChanged(object sender, System.Windows.Controls.SelectionChangedEventArgs e)
{
CheckOKButton();
}
private void doubleUpDownDraft_ValueChanged(object sender, RoutedPropertyChangedEventArgs<object> e)
{
CheckOKButton();
}
private void datePickerETA_ValueChanged(object sender, RoutedPropertyChangedEventArgs<object> e)
{
CheckOKButton();
}
private void comboBoxArrivalBerth_SelectionChanged(object sender, System.Windows.Controls.SelectionChangedEventArgs e)
{
CheckOKButton();
} }
#endregion #endregion

View File

@ -24,6 +24,9 @@
<RowDefinition Height="56" /> <RowDefinition Height="56" />
<RowDefinition Height="28" /> <RowDefinition Height="28" />
</Grid.RowDefinitions> </Grid.RowDefinitions>
<Button x:Name="buttonFixedOrder" Grid.Row="0" Grid.Column="1" Margin="2" Click="buttonFixedOrder_Click" Width="28" HorizontalAlignment="Left">
<Image x:Name="imageFixedOrder" Source="Resources\lock_open.png" />
</Button>
<!-- Label Grid.Row="0" Grid.Column="2" Content="{x:Static p:Resources.textFixed}" /--> <!-- Label Grid.Row="0" Grid.Column="2" Content="{x:Static p:Resources.textFixed}" /-->
<Label Grid.Row="1" Grid.Column="0" Content="{x:Static p:Resources.textETABerth}" HorizontalContentAlignment="Right" x:Name="labelETA" /> <Label Grid.Row="1" Grid.Column="0" Content="{x:Static p:Resources.textETABerth}" HorizontalContentAlignment="Right" x:Name="labelETA" />
<Label Grid.Row="2" Grid.Column="0" Content="{x:Static p:Resources.textETDBerth}" HorizontalContentAlignment="Right" x:Name="labelETD" /> <Label Grid.Row="2" Grid.Column="0" Content="{x:Static p:Resources.textETDBerth}" HorizontalContentAlignment="Right" x:Name="labelETD" />

View File

@ -4,7 +4,9 @@
// //
using BreCalClient.misc.Model; using BreCalClient.misc.Model;
using System;
using System.Windows; using System.Windows;
using System.Windows.Media.Imaging;
namespace BreCalClient namespace BreCalClient
{ {
@ -52,6 +54,14 @@ namespace BreCalClient
this.Close(); this.Close();
} }
private void buttonFixedOrder_Click(object sender, RoutedEventArgs e)
{
bool newValue = true;
if (this.Times.EtaBerthFixed ?? false)
newValue = false;
SetLockButton(newValue);
}
#endregion #endregion
#region private methods #region private methods
@ -87,13 +97,19 @@ namespace BreCalClient
this.labelETD.FontWeight = FontWeights.Bold; this.labelETD.FontWeight = FontWeights.Bold;
this.datePickerETDBerth.ContextMenu.IsEnabled = false; this.datePickerETDBerth.ContextMenu.IsEnabled = false;
break; break;
} }
this.SetLockButton(this.Times.EtaBerthFixed ?? false);
} }
private void EnableControls() private void EnableControls()
{ {
Extensions.ParticipantType pType = (Extensions.ParticipantType) this.Times.ParticipantType; Extensions.ParticipantType pType = (Extensions.ParticipantType) this.Times.ParticipantType;
if (this.Times.ParticipantId != App.Participant.Id) return; // if this is not "my" entry, there is no editing! if (this.Times.ParticipantId != App.Participant.Id)
{
this.buttonFixedOrder.IsEnabled = false;
return; // if this is not "my" entry, there is no editing!
}
switch (pType) switch (pType)
{ {
@ -117,6 +133,20 @@ namespace BreCalClient
this.buttonOK.IsEnabled = true; this.buttonOK.IsEnabled = true;
} }
private void SetLockButton(bool newValue)
{
if (newValue)
{
this.Times.EtaBerthFixed = true;
this.imageFixedOrder.Source = new BitmapImage(new Uri(@"pack://application:,,,/Resources/lock.png", UriKind.RelativeOrAbsolute));
}
else
{
this.Times.EtaBerthFixed = false;
this.imageFixedOrder.Source = new BitmapImage(new Uri(@"pack://application:,,,/Resources/lock_open.png", UriKind.RelativeOrAbsolute));
}
}
#endregion #endregion
#region clear value event handler #region clear value event handler
@ -139,9 +169,10 @@ namespace BreCalClient
private void contextMenuItemClearZoneEntry_Click(object sender, RoutedEventArgs e) private void contextMenuItemClearZoneEntry_Click(object sender, RoutedEventArgs e)
{ {
this.datePickerZoneEntry.Value = null; this.datePickerZoneEntry.Value = null;
} }
#endregion #endregion
} }
} }

View File

@ -0,0 +1,32 @@
<UserControl x:Class="BreCalClient.HistoryControl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:local="clr-namespace:BreCalClient"
xmlns:p = "clr-namespace:BreCalClient.Resources"
mc:Ignorable="d"
d:DesignHeight="46" d:DesignWidth="800">
<Border BorderBrush="Black" BorderThickness="0 0 0 .5">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="14" />
<RowDefinition Height="25" />
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition Width=".25*" />
<ColumnDefinition Width=".25*" />
<ColumnDefinition Width=".25*" />
<ColumnDefinition Width=".25*" />
</Grid.ColumnDefinitions>
<TextBlock Grid.Row="0" Grid.Column="0" FontSize="10" FontWeight="DemiBold" Text="{x:Static p:Resources.textShip}" VerticalAlignment="Center" Foreground="Gray" />
<TextBlock Grid.Row="0" Grid.Column="1" FontSize="10" FontWeight="DemiBold" Text="{x:Static p:Resources.textTimestamp}" VerticalAlignment="Center" Foreground="Gray"/>
<TextBlock Grid.Row="0" Grid.Column="2" FontSize="10" FontWeight="DemiBold" Text="{x:Static p:Resources.textOperation}" VerticalAlignment="Center" Foreground="Gray"/>
<TextBlock Grid.Row="0" Grid.Column="3" FontSize="10" FontWeight="DemiBold" Text="{x:Static p:Resources.textParticipant}" VerticalAlignment="Center" Foreground="Gray"/>
<TextBlock Grid.Row="1" Grid.Column="0" x:Name="textBlockShip" FontWeight="DemiBold" />
<TextBlock Grid.Row="1" Grid.Column="1" x:Name="textBlockTimestamp" />
<TextBlock Grid.Row="1" Grid.Column="2" x:Name="textBlockOperation" />
<TextBlock Grid.Row="1" Grid.Column="3" x:Name="textBlockParticipant" />
</Grid>
</Border>
</UserControl>

View File

@ -0,0 +1,27 @@
// Copyright (c) 2024- schick Informatik
// Description: display single history element (later shown in a list)
//
using BreCalClient.misc.Model;
using System.Windows.Controls;
namespace BreCalClient
{
/// <summary>
/// Interaction logic for HistoryControl.xaml
/// </summary>
public partial class HistoryControl : UserControl
{
public HistoryControl(string ship, History history)
{
InitializeComponent();
this.textBlockOperation.Text = $"{history.Operation} on {history.Type}";
this.textBlockShip.Text = ship;
if(BreCalLists.ParticipantLookupDict.ContainsKey(history.ParticipantId))
this.textBlockParticipant.Text = BreCalLists.ParticipantLookupDict[history.ParticipantId].Name;
this.textBlockTimestamp.Text = history.Timestamp.ToString();
}
}
}

View File

@ -0,0 +1,21 @@
<Window x:Class="BreCalClient.HistoryDialog"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:BreCalClient"
xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
xmlns:p = "clr-namespace:BreCalClient.Resources"
mc:Ignorable="d" Left="{local:SettingBinding W1Left}" Top="{local:SettingBinding W1Top}"
Title="{x:Static p:Resources.textChangeHistory}" Height="450" Width="800" Loaded="Window_Loaded">
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*" />
<RowDefinition Height="28" />
</Grid.RowDefinitions>
<ScrollViewer Grid.Row="0" VerticalScrollBarVisibility="Auto" Margin="2">
<StackPanel x:Name="stackPanel"/>
</ScrollViewer>
<Button x:Name="buttonClose" Click="buttonClose_Click" Content="{x:Static p:Resources.textClose}" Width="80" Margin="2" Grid.Row="1" HorizontalAlignment="Right" />
</Grid>
</Window>

View File

@ -0,0 +1,81 @@
// Copyright (c) 2024- schick Informatik
// Description: Window to show (complete) list of current shipcall histories
//
using BreCalClient.misc.Api;
using BreCalClient.misc.Model;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Windows;
namespace BreCalClient
{
/// <summary>
/// Interaction logic for HistoryDialog.xaml
/// </summary>
public partial class HistoryDialog : Window
{
#region Fields
private readonly ConcurrentDictionary<int, ShipcallControlModel> _shipcalls;
private readonly StaticApi _staticApi;
#endregion
#region Construction
public HistoryDialog(ConcurrentDictionary<int, ShipcallControlModel> shipcalls, StaticApi staticApi)
{
InitializeComponent();
_shipcalls = shipcalls;
_staticApi = staticApi;
}
#endregion
#region event handler
private void Window_Loaded(object sender, RoutedEventArgs e)
{
RefreshHistory();
}
private void buttonClose_Click(object sender, RoutedEventArgs e)
{
this.Close();
}
#endregion
#region private methods
private async void RefreshHistory()
{
List<History> allHistories = new();
foreach (int shipcall_id in _shipcalls.Keys)
{
List<History> shipcallHistory = await _staticApi.HistoryGetAsync(shipcall_id);
System.Diagnostics.Trace.WriteLine($"{shipcallHistory.Count} history elements loaded for shipcall {shipcall_id}");
allHistories.AddRange( shipcallHistory );
}
// sort all entries
allHistories.Sort((x, y) => { return y.Timestamp.CompareTo(x.Timestamp); });
// create controls for all entries
foreach (History history in allHistories)
{
string shipname = "";
Ship? ship = this._shipcalls[history.ShipcallId].Ship;
if (ship != null)
shipname = ship.Name;
HistoryControl hc = new(shipname, history);
this.stackPanel.Children.Add(hc);
}
}
#endregion
}
}

View File

@ -106,14 +106,18 @@
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="120" /> <ColumnDefinition Width="120" />
<ColumnDefinition Width="Auto" /> <ColumnDefinition Width="Auto" />
<ColumnDefinition Width="100" /> <ColumnDefinition Width="80" />
<ColumnDefinition Width="Auto" /> <ColumnDefinition Width="Auto" />
<ColumnDefinition Width="120" /> <ColumnDefinition Width="120" />
<ColumnDefinition Width="Auto" /> <ColumnDefinition Width="Auto" />
<ColumnDefinition Width="30" /> <ColumnDefinition Width="26" />
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="26" />
<ColumnDefinition Width="Auto" /> <ColumnDefinition Width="Auto" />
<ColumnDefinition Width="*" /> <ColumnDefinition Width="*" />
<ColumnDefinition Width="Auto" /> <ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="Auto" />
<ColumnDefinition Width="100" /> <ColumnDefinition Width="100" />
</Grid.ColumnDefinitions> </Grid.ColumnDefinitions>
</Grid> </Grid>
@ -132,15 +136,25 @@
</StatusBarItem> </StatusBarItem>
<Separator Grid.Column="5"/> <Separator Grid.Column="5"/>
<StatusBarItem Grid.Column="6"> <StatusBarItem Grid.Column="6">
<Button x:Name="buttonInfo" Content="?" Click="buttonInfo_Click" Width="20" /> <Button x:Name="buttonInfo" Content="?" Click="buttonInfo_Click" Width="20" ToolTip="{x:Static p:Resources.textInfoChangePW}"/>
</StatusBarItem> </StatusBarItem>
<Separator Grid.Column="7"/> <Separator Grid.Column="7"/>
<StatusBarItem Grid.Column="8"> <StatusBarItem Grid.Column="8">
<TextBlock Name="labelStatusBar"></TextBlock> <Button x:Name="buttonHistory" Click="buttonHistory_Click" Width="20" ToolTip="{x:Static p:Resources.textShowHistory}">
<Image Source="./Resources/clock.png"/>
</Button>
</StatusBarItem> </StatusBarItem>
<Separator Grid.Column="9"/> <Separator Grid.Column="9"/>
<StatusBarItem Grid.Column="10"> <StatusBarItem Grid.Column="10">
<ProgressBar Name="generalProgressStatus" Width="90" Height="16"/> <TextBlock Name="labelStatusBar"></TextBlock>
</StatusBarItem>
<Separator Grid.Column="11"/>
<StatusBarItem Grid.Column="12">
<TextBlock x:Name="labelLatestUpdate" />
</StatusBarItem>
<Separator Grid.Column="13"/>
<StatusBarItem Grid.Column="14">
<ProgressBar Name="generalProgressStatus" Width="90" Height="16" Foreground="LightGray"/>
</StatusBarItem> </StatusBarItem>
</StatusBar> </StatusBar>
</Grid> </Grid>

View File

@ -32,8 +32,8 @@ namespace BreCalClient
public partial class MainWindow : Window public partial class MainWindow : Window
{ {
private readonly ILog _log = LogManager.GetLogger(typeof(MainWindow)); private readonly ILog _log = LogManager.GetLogger(typeof(MainWindow));
private const int SHIPCALL_UPDATE_INTERVAL_SECONDS = 30; private const int SHIPCALL_UPDATE_INTERVAL_SECONDS = 30;
private const int PROGRESS_STEPS = 50;
#region Fields #region Fields
@ -49,7 +49,7 @@ namespace BreCalClient
private readonly UserApi _userApi; private readonly UserApi _userApi;
private readonly TimesApi _timesApi; private readonly TimesApi _timesApi;
private readonly StaticApi _staticApi; private readonly StaticApi _staticApi;
private readonly ShipApi _shipApi; private readonly ShipApi _shipApi;
private CancellationTokenSource _tokenSource = new(); private CancellationTokenSource _tokenSource = new();
private LoginResult? _loginResult; private LoginResult? _loginResult;
@ -61,6 +61,7 @@ namespace BreCalClient
// private bool _filterChanged = false; // private bool _filterChanged = false;
// private bool _sequenceChanged = false; // private bool _sequenceChanged = false;
private HistoryDialog? _historyDialog;
#endregion #endregion
@ -112,6 +113,7 @@ namespace BreCalClient
Trace.WriteLine("token refreshed"); Trace.WriteLine("token refreshed");
}); });
RetryConfiguration.AsyncRetryPolicy = retryPolicy; RetryConfiguration.AsyncRetryPolicy = retryPolicy;
this.generalProgressStatus.Maximum = PROGRESS_STEPS;
} }
#endregion #endregion
@ -349,6 +351,20 @@ namespace BreCalClient
this.UpdateUI(); this.UpdateUI();
} }
private void buttonHistory_Click(object sender, RoutedEventArgs e)
{
if(_historyDialog == null)
{
_historyDialog = new HistoryDialog(_allShipcallsDict, _staticApi);
_historyDialog.Closed += (sender, e) => { this._historyDialog = null; };
_historyDialog.Show();
}
else
{
_historyDialog.Activate();
}
}
#endregion #endregion
#region network operations #region network operations
@ -403,8 +419,9 @@ namespace BreCalClient
this.Dispatcher.Invoke(new Action(() => this.Dispatcher.Invoke(new Action(() =>
{ {
labelGeneralStatus.Text = $"Connection {ConnectionStatus.SUCCESSFUL}"; labelGeneralStatus.Text = $"Connection {ConnectionStatus.SUCCESSFUL}";
labelGeneralStatus.Text = $"Ok"; labelLatestUpdate.Text = $"Last update: {DateTime.Now.ToLongTimeString()}";
generalProgressStatus.Value = 0;
})); }));
} }
catch (Exception ex) catch (Exception ex)
@ -463,7 +480,15 @@ namespace BreCalClient
try try
{ {
await Task.Delay(TimeSpan.FromSeconds(SHIPCALL_UPDATE_INTERVAL_SECONDS), _tokenSource.Token); double interval = (double) SHIPCALL_UPDATE_INTERVAL_SECONDS / PROGRESS_STEPS;
for (int i = 0; i < PROGRESS_STEPS; i++)
{
await Task.Delay(TimeSpan.FromSeconds(interval), _tokenSource.Token);
this.Dispatcher.Invoke(new Action(() =>
{
this.generalProgressStatus.Value = i;
}));
}
} }
catch(TaskCanceledException) { } catch(TaskCanceledException) { }
} }
@ -498,7 +523,7 @@ namespace BreCalClient
{ {
ShipcallControl sc = new() ShipcallControl sc = new()
{ {
Height = 120, Height = 135,
ShipcallControlModel = scm ShipcallControlModel = scm
}; };
sc.EditTimesRequested += Sc_EditTimesRequested; sc.EditTimesRequested += Sc_EditTimesRequested;
@ -650,6 +675,22 @@ namespace BreCalClient
}); });
} }
if(sfm.MineOnly ?? false)
{
_ = _visibleControlModels.RemoveAll(x =>
{
bool contained = false;
foreach(ParticipantAssignment p in x.AssignedParticipants.Values)
{
if(p.ParticipantId.Equals(App.Participant.Id))
{
contained = true; break;
}
}
return !contained;
});
}
if(!_showCanceled ?? true) // canceled calls are filtered by default if(!_showCanceled ?? true) // canceled calls are filtered by default
{ {
_ = this._visibleControlModels.RemoveAll(x => x.Shipcall?.Canceled ?? false); _ = this._visibleControlModels.RemoveAll(x => x.Shipcall?.Canceled ?? false);
@ -914,6 +955,6 @@ namespace BreCalClient
} }
#endregion #endregion
} }
} }

View File

@ -60,6 +60,16 @@ namespace BreCalClient.Resources {
} }
} }
/// <summary>
/// Looks up a localized resource of type System.Byte[].
/// </summary>
public static byte[] _lock {
get {
object obj = ResourceManager.GetObject("_lock", resourceCulture);
return ((byte[])(obj));
}
}
/// <summary> /// <summary>
/// Looks up a localized resource of type System.Byte[]. /// Looks up a localized resource of type System.Byte[].
/// </summary> /// </summary>
@ -210,6 +220,16 @@ namespace BreCalClient.Resources {
} }
} }
/// <summary>
/// Looks up a localized resource of type System.Byte[].
/// </summary>
public static byte[] lock_open {
get {
object obj = ResourceManager.GetObject("lock_open", resourceCulture);
return ((byte[])(obj));
}
}
/// <summary> /// <summary>
/// Looks up a localized resource of type System.Byte[]. /// Looks up a localized resource of type System.Byte[].
/// </summary> /// </summary>
@ -384,6 +404,15 @@ namespace BreCalClient.Resources {
} }
} }
/// <summary>
/// Looks up a localized string similar to Change history.
/// </summary>
public static string textChangeHistory {
get {
return ResourceManager.GetString("textChangeHistory", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to Change password. /// Looks up a localized string similar to Change password.
/// </summary> /// </summary>
@ -573,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> /// <summary>
/// Looks up a localized string similar to from. /// Looks up a localized string similar to from.
/// </summary> /// </summary>
@ -591,6 +629,15 @@ namespace BreCalClient.Resources {
} }
} }
/// <summary>
/// Looks up a localized string similar to Show app info and change user password.
/// </summary>
public static string textInfoChangePW {
get {
return ResourceManager.GetString("textInfoChangePW", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to Interval. /// Looks up a localized string similar to Interval.
/// </summary> /// </summary>
@ -636,6 +683,15 @@ namespace BreCalClient.Resources {
} }
} }
/// <summary>
/// Looks up a localized string similar to mine only.
/// </summary>
public static string textMineOnly {
get {
return ResourceManager.GetString("textMineOnly", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to Moored in lock. /// Looks up a localized string similar to Moored in lock.
/// </summary> /// </summary>
@ -699,6 +755,15 @@ namespace BreCalClient.Resources {
} }
} }
/// <summary>
/// Looks up a localized string similar to Operation.
/// </summary>
public static string textOperation {
get {
return ResourceManager.GetString("textOperation", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to Operations end. /// Looks up a localized string similar to Operations end.
/// </summary> /// </summary>
@ -726,6 +791,15 @@ namespace BreCalClient.Resources {
} }
} }
/// <summary>
/// Looks up a localized string similar to Participant.
/// </summary>
public static string textParticipant {
get {
return ResourceManager.GetString("textParticipant", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to Participants. /// Looks up a localized string similar to Participants.
/// </summary> /// </summary>
@ -924,6 +998,15 @@ namespace BreCalClient.Resources {
} }
} }
/// <summary>
/// Looks up a localized string similar to Show shipcall change history.
/// </summary>
public static string textShowHistory {
get {
return ResourceManager.GetString("textShowHistory", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to Sort order. /// Looks up a localized string similar to Sort order.
/// </summary> /// </summary>
@ -960,6 +1043,15 @@ namespace BreCalClient.Resources {
} }
} }
/// <summary>
/// Looks up a localized string similar to Timestamp.
/// </summary>
public static string textTimestamp {
get {
return ResourceManager.GetString("textTimestamp", resourceCulture);
}
}
/// <summary> /// <summary>
/// Looks up a localized string similar to to. /// Looks up a localized string similar to to.
/// </summary> /// </summary>

View File

@ -1,17 +1,17 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<root> <root>
<!-- <!--
Microsoft ResX Schema Microsoft ResX Schema
Version 2.0 Version 2.0
The primary goals of this format is to allow a simple XML format The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes various data types are done through the TypeConverter classes
associated with the data types. associated with the data types.
Example: Example:
... ado.net/XML headers & schema ... ... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader> <resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader> <resheader name="version">2.0</resheader>
@ -26,36 +26,36 @@
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value> <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment> <comment>This is a comment</comment>
</data> </data>
There are any number of "resheader" rows that contain simple There are any number of "resheader" rows that contain simple
name/value pairs. name/value pairs.
Each data row contains a name, and value. The row also contains a Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture. text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the Classes that don't support this are serialized and stored with the
mimetype set. mimetype set.
The mimetype is used for serialized objects, and tells the The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly: extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below. read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64 mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding. : and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64 mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding. : and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64 mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter : using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding. : and then encoded with base64 encoding.
--> -->
@ -218,7 +218,7 @@
<value>Zeitraum</value> <value>Zeitraum</value>
</data> </data>
<data name="textLengthWidth" xml:space="preserve"> <data name="textLengthWidth" xml:space="preserve">
<value>L/B</value> <value>L/B (m)</value>
</data> </data>
<data name="textLogin" xml:space="preserve"> <data name="textLogin" xml:space="preserve">
<value>Anmelden</value> <value>Anmelden</value>
@ -448,4 +448,28 @@
<data name="textTugCompany" xml:space="preserve"> <data name="textTugCompany" xml:space="preserve">
<value>Schlepper-Reederei</value> <value>Schlepper-Reederei</value>
</data> </data>
<data name="textChangeHistory" xml:space="preserve">
<value>Verlauf</value>
</data>
<data name="textInfoChangePW" xml:space="preserve">
<value>App Info anzeigen und Passwort ändern</value>
</data>
<data name="textShowHistory" xml:space="preserve">
<value>Änderungshistorie der Anläufe anzeigen</value>
</data>
<data name="textMineOnly" xml:space="preserve">
<value>nur eigene</value>
</data>
<data name="textOperation" xml:space="preserve">
<value>Vorgang</value>
</data>
<data name="textParticipant" xml:space="preserve">
<value>Teilnehmer</value>
</data>
<data name="textTimestamp" xml:space="preserve">
<value>Zeitpunkt</value>
</data>
<data name="textFixedOrder" xml:space="preserve">
<value>Als feste Bestellung vermerkt</value>
</data>
</root> </root>

View File

@ -163,6 +163,9 @@
<data name="emergency_stop_button" type="System.Resources.ResXFileRef, System.Windows.Forms"> <data name="emergency_stop_button" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>emergency_stop_button.png;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>emergency_stop_button.png;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data> </data>
<data name="lock_open" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>lock_open.png;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name="logo_bremen_calling" type="System.Resources.ResXFileRef, System.Windows.Forms"> <data name="logo_bremen_calling" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>logo_bremen_calling.png;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>logo_bremen_calling.png;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data> </data>
@ -220,6 +223,9 @@
<data name="textChangeContactInfo" xml:space="preserve"> <data name="textChangeContactInfo" xml:space="preserve">
<value>Update contact info</value> <value>Update contact info</value>
</data> </data>
<data name="textChangeHistory" xml:space="preserve">
<value>Change history</value>
</data>
<data name="textChangePassword" xml:space="preserve"> <data name="textChangePassword" xml:space="preserve">
<value>Change password</value> <value>Change password</value>
</data> </data>
@ -283,12 +289,18 @@
<data name="textFixed" xml:space="preserve"> <data name="textFixed" xml:space="preserve">
<value>Fixed</value> <value>Fixed</value>
</data> </data>
<data name="textFixedOrder" xml:space="preserve">
<value>Marked as a fixed order</value>
</data>
<data name="textFrom" xml:space="preserve"> <data name="textFrom" xml:space="preserve">
<value>from</value> <value>from</value>
</data> </data>
<data name="textIncoming" xml:space="preserve"> <data name="textIncoming" xml:space="preserve">
<value>Incoming</value> <value>Incoming</value>
</data> </data>
<data name="textInfoChangePW" xml:space="preserve">
<value>Show app info and change user password</value>
</data>
<data name="textInterval" xml:space="preserve"> <data name="textInterval" xml:space="preserve">
<value>Interval</value> <value>Interval</value>
</data> </data>
@ -304,6 +316,9 @@
<data name="textLogin" xml:space="preserve"> <data name="textLogin" xml:space="preserve">
<value>Login</value> <value>Login</value>
</data> </data>
<data name="textMineOnly" xml:space="preserve">
<value>mine only</value>
</data>
<data name="textMooredLock" xml:space="preserve"> <data name="textMooredLock" xml:space="preserve">
<value>Moored in lock</value> <value>Moored in lock</value>
</data> </data>
@ -325,6 +340,9 @@
<data name="textOldPassword" xml:space="preserve"> <data name="textOldPassword" xml:space="preserve">
<value>Old password</value> <value>Old password</value>
</data> </data>
<data name="textOperation" xml:space="preserve">
<value>Operation</value>
</data>
<data name="textOperationsEnd" xml:space="preserve"> <data name="textOperationsEnd" xml:space="preserve">
<value>Operations end</value> <value>Operations end</value>
</data> </data>
@ -334,6 +352,9 @@
<data name="textOutgoing" xml:space="preserve"> <data name="textOutgoing" xml:space="preserve">
<value>Outgoing</value> <value>Outgoing</value>
</data> </data>
<data name="textParticipant" xml:space="preserve">
<value>Participant</value>
</data>
<data name="textParticipants" xml:space="preserve"> <data name="textParticipants" xml:space="preserve">
<value>Participants</value> <value>Participants</value>
</data> </data>
@ -400,6 +421,9 @@
<data name="textShowCancelledShipcalls" xml:space="preserve"> <data name="textShowCancelledShipcalls" xml:space="preserve">
<value>Show cancelled calls</value> <value>Show cancelled calls</value>
</data> </data>
<data name="textShowHistory" xml:space="preserve">
<value>Show shipcall change history</value>
</data>
<data name="textSortOrder" xml:space="preserve"> <data name="textSortOrder" xml:space="preserve">
<value>Sort order</value> <value>Sort order</value>
</data> </data>
@ -412,6 +436,9 @@
<data name="textTidalWindow" xml:space="preserve"> <data name="textTidalWindow" xml:space="preserve">
<value>Tidal window</value> <value>Tidal window</value>
</data> </data>
<data name="textTimestamp" xml:space="preserve">
<value>Timestamp</value>
</data>
<data name="textTo" xml:space="preserve"> <data name="textTo" xml:space="preserve">
<value>to</value> <value>to</value>
</data> </data>
@ -475,4 +502,7 @@
<data name="worker2" type="System.Resources.ResXFileRef, System.Windows.Forms"> <data name="worker2" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>worker2.png;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value> <value>worker2.png;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data> </data>
<data name="_lock" type="System.Resources.ResXFileRef, System.Windows.Forms">
<value>lock.png;System.Byte[], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
</root> </root>

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

View File

@ -74,8 +74,17 @@
<Label Grid.Column="1" Content="{x:Static p:Resources.textTo}" /> <Label Grid.Column="1" Content="{x:Static p:Resources.textTo}" />
<xctk:DoubleUpDown x:Name="upDownShiplengthTo" Grid.Column="2" Margin="2" Minimum="0" Maximum="1000" ValueChanged="upDownShiplengthTo_ValueChanged" Value="{Binding Path=ShipLengthTo}"/> <xctk:DoubleUpDown x:Name="upDownShiplengthTo" Grid.Column="2" Margin="2" Minimum="0" Maximum="1000" ValueChanged="upDownShiplengthTo_ValueChanged" Value="{Binding Path=ShipLengthTo}"/>
</Grid> </Grid>
<xctk:WatermarkTextBox x:Name="textBoxSearch" Grid.Column="2" Grid.Row="1" Margin="2" Watermark="{x:Static p:Resources.textEnterKeyword}" PreviewTextInput="textBoxSearch_PreviewTextInput" <Grid Grid.Column="2" Grid.Row="1">
<Grid.ColumnDefinitions>
<ColumnDefinition Width=".5*" />
<ColumnDefinition Width="30" />
<ColumnDefinition Width=".5*" />
</Grid.ColumnDefinitions>
<xctk:WatermarkTextBox x:Name="textBoxSearch" Grid.Column="0" Margin="2" Watermark="{x:Static p:Resources.textEnterKeyword}" PreviewTextInput="textBoxSearch_PreviewTextInput"
DataObject.Pasting="textBoxSearch_Pasting" TextChanged="textBoxSearch_TextChanged" /> DataObject.Pasting="textBoxSearch_Pasting" TextChanged="textBoxSearch_TextChanged" />
<CheckBox x:Name="checkBoxOwn" VerticalAlignment="Center" Grid.Column="1" HorizontalAlignment="Right" Margin="2" Checked="checkBoxOwn_Checked" Unchecked="checkBoxOwn_Checked" />
<Label Content="{x:Static p:Resources.textMineOnly}" Grid.Column="2" />
</Grid>
<xctk:CheckComboBox x:Name="comboBoxBerths" DisplayMemberPath="Name" Grid.Column="4" Grid.Row="1" Margin="2" ItemSelectionChanged="comboBoxBerths_ItemSelectionChanged" /> <xctk:CheckComboBox x:Name="comboBoxBerths" DisplayMemberPath="Name" Grid.Column="4" Grid.Row="1" Margin="2" ItemSelectionChanged="comboBoxBerths_ItemSelectionChanged" />
<xctk:CheckComboBox x:Name="comboBoxAgencies" DisplayMemberPath="Name" Grid.Column="6" Grid.Row="1" Margin="2" ItemSelectionChanged="comboBoxAgencies_ItemSelectionChanged" /> <xctk:CheckComboBox x:Name="comboBoxAgencies" DisplayMemberPath="Name" Grid.Column="6" Grid.Row="1" Margin="2" ItemSelectionChanged="comboBoxAgencies_ItemSelectionChanged" />
</Grid> </Grid>

View File

@ -76,7 +76,8 @@ namespace BreCalClient
this.datePickerETATo.SelectedDate = null; this.datePickerETATo.SelectedDate = null;
this.textBoxSearch.Clear(); this.textBoxSearch.Clear();
this.upDownShiplengthFrom.Value = null; this.upDownShiplengthFrom.Value = null;
this.upDownShiplengthTo.Value = null; this.upDownShiplengthTo.Value = null;
this.checkBoxOwn.IsChecked = false;
} }
@ -108,6 +109,7 @@ namespace BreCalClient
this.upDownShiplengthTo.Value = sfm.ShipLengthTo; this.upDownShiplengthTo.Value = sfm.ShipLengthTo;
this.datePickerETAFrom.SelectedDate = sfm.EtaFrom; this.datePickerETAFrom.SelectedDate = sfm.EtaFrom;
this.datePickerETATo.SelectedDate = sfm.EtaTo; this.datePickerETATo.SelectedDate = sfm.EtaTo;
this.checkBoxOwn.IsChecked = sfm.MineOnly;
this._model = sfm; this._model = sfm;
SearchFilterChanged?.Invoke(); SearchFilterChanged?.Invoke();
@ -192,6 +194,12 @@ namespace BreCalClient
{ {
this.SearchFilter.SearchString = this.textBoxSearch.Text; this.SearchFilter.SearchString = this.textBoxSearch.Text;
SearchFilterChanged?.Invoke(); SearchFilterChanged?.Invoke();
}
private void checkBoxOwn_Checked(object sender, System.Windows.RoutedEventArgs e)
{
this._model.MineOnly = this.checkBoxOwn.IsChecked;
SearchFilterChanged?.Invoke();
} }
#endregion #endregion

View File

@ -31,8 +31,12 @@ namespace BreCalClient
public double? ShipLengthTo { get; set; } public double? ShipLengthTo { get; set; }
public bool? MineOnly { get; set; }
#endregion #endregion
#region Serialisation
public static SearchFilterModel? Deserialize(string json) public static SearchFilterModel? Deserialize(string json)
{ {
return (SearchFilterModel?) JsonConvert.DeserializeObject(json, typeof(SearchFilterModel)); return (SearchFilterModel?) JsonConvert.DeserializeObject(json, typeof(SearchFilterModel));
@ -43,5 +47,7 @@ namespace BreCalClient
return JsonConvert.SerializeObject(this, Formatting.Indented); return JsonConvert.SerializeObject(this, Formatting.Indented);
} }
#endregion
} }
} }

View File

@ -7,7 +7,7 @@
xmlns:sets="clr-namespace:BreCalClient.Properties" xmlns:sets="clr-namespace:BreCalClient.Properties"
xmlns:db="clr-namespace:BreCalClient;assembly=BreCalDevelClient" xmlns:db="clr-namespace:BreCalClient;assembly=BreCalDevelClient"
mc:Ignorable="d" mc:Ignorable="d"
d:DesignHeight="120" d:DesignWidth="800" Loaded="UserControl_Loaded"> d:DesignHeight="135" d:DesignWidth="800" Loaded="UserControl_Loaded">
<Border BorderBrush="LightGray" Margin="1" BorderThickness="1"> <Border BorderBrush="LightGray" Margin="1" BorderThickness="1">
<Grid> <Grid>
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
@ -30,7 +30,7 @@
<RowDefinition Height=".125*"/> <RowDefinition Height=".125*"/>
<RowDefinition Height=".125*"/> <RowDefinition Height=".125*"/>
<RowDefinition Height=".05*"/> <RowDefinition Height=".125*"/>
<RowDefinition Height=".125*"/> <RowDefinition Height=".125*"/>
<RowDefinition Height=".125*"/> <RowDefinition Height=".125*"/>
</Grid.RowDefinitions> </Grid.RowDefinitions>
@ -71,6 +71,12 @@
<Viewbox Grid.Row="3" Grid.Column="1" HorizontalAlignment="Left"> <Viewbox Grid.Row="3" Grid.Column="1" HorizontalAlignment="Left">
<TextBlock x:Name="textBlockLengthWidth" Padding="0"/> <TextBlock x:Name="textBlockLengthWidth" Padding="0"/>
</Viewbox> </Viewbox>
<Viewbox Grid.Row="4" Grid.Column="0" HorizontalAlignment="Left">
<TextBlock Text="{x:Static p:Resources.textDraft}" Padding="0" />
</Viewbox>
<Viewbox Grid.Row="4" Grid.Column="1" HorizontalAlignment="Left">
<TextBlock x:Name="textBlockDraft" Padding="0"/>
</Viewbox>
<Viewbox Grid.Row="5" Grid.Column="0" HorizontalAlignment="Left"> <Viewbox Grid.Row="5" Grid.Column="0" HorizontalAlignment="Left">
<TextBlock Text="ETA" x:Name="labelETA"/> <TextBlock Text="ETA" x:Name="labelETA"/>
</Viewbox> </Viewbox>
@ -126,7 +132,7 @@
</Border> </Border>
<!-- MOORING --> <!-- MOORING -->
<Border Grid.Row="2" Grid.Column="2" BorderThickness="1, 0, 0, 0" BorderBrush="{Binding Source={x:Static sets:Settings.Default}, Path=BG_COLOR}" Padding="3,0,0,0"> <Border Grid.Row="2" Grid.Column="2" BorderThickness="1, 0, 0, 0" BorderBrush="{Binding Source={x:Static sets:Settings.Default}, Path=BG_COLOR}" Padding="3,0,0,0">
<Grid> <Grid x:Name="gridMooring">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="0.3*" /> <ColumnDefinition Width="0.3*" />
<ColumnDefinition Width="0.7*" /> <ColumnDefinition Width="0.7*" />
@ -138,13 +144,14 @@
<Label Grid.Row="0" x:Name="labelETAETDMooring" Grid.Column="0" Content="ETA" Padding="0" VerticalContentAlignment="Center" /> <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="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"/> <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"/> <TextBlock Grid.Row="1" Grid.Column="1" Padding="0" TextWrapping="Wrap" VerticalAlignment="Top" x:Name="textBlockMooringRemarks"/>
</Grid> </Grid>
</Border> </Border>
<!-- PORT AUTHORITY --> <!-- PORT AUTHORITY -->
<Border Grid.Row="2" Grid.Column="3" BorderThickness="1, 0, 0, 0" BorderBrush="{Binding Source={x:Static sets:Settings.Default}, Path=BG_COLOR}" Padding="3,0,0,0"> <Border Grid.Row="2" Grid.Column="3" BorderThickness="1, 0, 0, 0" BorderBrush="{Binding Source={x:Static sets:Settings.Default}, Path=BG_COLOR}" Padding="3,0,0,0">
<Grid > <Grid x:Name="gridPortAuthority">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="0.3*" /> <ColumnDefinition Width="0.3*" />
<ColumnDefinition Width="0.7*" /> <ColumnDefinition Width="0.7*" />
@ -156,12 +163,13 @@
<Label Grid.Row="0" Grid.Column="0" x:Name="labelETAETDPortAuthority" Content="ETA" Padding="0" VerticalContentAlignment="Center" /> <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="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"/> <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"/> <TextBlock Grid.Row="1" Grid.Column="1" Padding="0" TextWrapping="Wrap" VerticalAlignment="Top" x:Name="textBlockPortAuthorityRemarks"/>
</Grid> </Grid>
</Border> </Border>
<!-- PILOT --> <!-- PILOT -->
<Border Grid.Row="2" Grid.Column="4" BorderThickness="1, 0, 0, 0" BorderBrush="{Binding Source={x:Static sets:Settings.Default}, Path=BG_COLOR}" Padding="3,0,0,0"> <Border Grid.Row="2" Grid.Column="4" BorderThickness="1, 0, 0, 0" BorderBrush="{Binding Source={x:Static sets:Settings.Default}, Path=BG_COLOR}" Padding="3,0,0,0">
<Grid > <Grid x:Name="gridPilot">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="0.3*" /> <ColumnDefinition Width="0.3*" />
<ColumnDefinition Width="0.7*" /> <ColumnDefinition Width="0.7*" />
@ -173,12 +181,13 @@
<Label Grid.Row="0" Grid.Column="0" x:Name="labelETAETDPilot" Content="ETA" Padding="0" VerticalContentAlignment="Center" /> <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="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"/> <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"/> <TextBlock Grid.Row="1" Grid.Column="1" Padding="0" TextWrapping="Wrap" VerticalAlignment="Top" x:Name="textBlockPilotRemarks"/>
</Grid> </Grid>
</Border> </Border>
<!-- TUG --> <!-- TUG -->
<Border Grid.Row="2" Grid.Column="5" BorderThickness="1, 0, 0, 0" BorderBrush="{Binding Source={x:Static sets:Settings.Default}, Path=BG_COLOR}" Padding="3,0,0,0"> <Border Grid.Row="2" Grid.Column="5" BorderThickness="1, 0, 0, 0" BorderBrush="{Binding Source={x:Static sets:Settings.Default}, Path=BG_COLOR}" Padding="3,0,0,0">
<Grid> <Grid x:Name="gridTug">
<Grid.ColumnDefinitions> <Grid.ColumnDefinitions>
<ColumnDefinition Width="0.3*" /> <ColumnDefinition Width="0.3*" />
<ColumnDefinition Width="0.7*" /> <ColumnDefinition Width="0.7*" />
@ -190,6 +199,7 @@
<Label Grid.Row="0" Grid.Column="0" x:Name="labelETAETDTug" Content="ETA" Padding="0" VerticalContentAlignment="Center" /> <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="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"/> <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"/> <TextBlock Grid.Row="1" Grid.Column="1" Padding="0" TextWrapping="Wrap" VerticalAlignment="Top" x:Name="textBlockTugRemarks"/>
</Grid> </Grid>
</Border> </Border>

View File

@ -78,6 +78,7 @@ namespace BreCalClient
this.labelAgencyETAETDValue.Content = ""; this.labelAgencyETAETDValue.Content = "";
this.textBlockAgencyRemarks.Text = ""; this.textBlockAgencyRemarks.Text = "";
this.textBlockAgencyBerthRemarks.Text = ""; this.textBlockAgencyBerthRemarks.Text = "";
this.textBlockDraft.Text = "";
} }
_mooring = this.ShipcallControlModel.GetParticipantForType(Extensions.ParticipantType.MOORING); _mooring = this.ShipcallControlModel.GetParticipantForType(Extensions.ParticipantType.MOORING);
@ -306,14 +307,15 @@ namespace BreCalClient
Times? agencyTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.AGENCY); Times? agencyTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.AGENCY);
if (agencyTimes != null) if (agencyTimes != null)
{ {
this.labelAgencyBerth.Content = this.ShipcallControlModel?.GetBerthText(agencyTimes); this.labelAgencyBerth.Content = this.ShipcallControlModel?.GetBerthText(agencyTimes);
this.labelAgencyETAETDValue.Content = agencyTimes.EtaBerth.HasValue ? agencyTimes.EtaBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -"; this.labelAgencyETAETDValue.Content = agencyTimes.EtaBerth.HasValue ? agencyTimes.EtaBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -";
this.textBlockAgencyRemarks.Text = agencyTimes.Remarks; this.textBlockAgencyRemarks.Text = agencyTimes.Remarks;
this.textBlockAgencyBerthRemarks.Text = agencyTimes.BerthInfo; this.textBlockAgencyBerthRemarks.Text = agencyTimes.BerthInfo;
if (this.ShipcallControlModel?.Shipcall?.Type != ShipcallType.Arrival) if (this.ShipcallControlModel?.Shipcall?.Type != ShipcallType.Arrival)
{ {
this.labelAgencyETAETDValue.Content = agencyTimes.EtdBerth.HasValue ? agencyTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -"; this.labelAgencyETAETDValue.Content = agencyTimes.EtdBerth.HasValue ? agencyTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -";
} }
this.textBlockDraft.Text = ShipcallControlModel?.Shipcall?.Draft?.ToString("N2");
} }
else else
{ {
@ -322,9 +324,11 @@ namespace BreCalClient
this.labelAgencyETAETDValue.Content = "- / -"; this.labelAgencyETAETDValue.Content = "- / -";
this.textBlockAgencyRemarks.Text = ""; this.textBlockAgencyRemarks.Text = "";
this.textBlockAgencyBerthRemarks.Text = ""; this.textBlockAgencyBerthRemarks.Text = "";
this.textBlockDraft.Text = "";
} }
Times? mooringTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.MOORING); Times? mooringTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.MOORING);
if (mooringTimes != null) if (mooringTimes != null)
{ {
@ -334,11 +338,13 @@ namespace BreCalClient
{ {
this.labelMooringETAETDValue.Content = mooringTimes.EtdBerth.HasValue ? mooringTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -"; 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 else
{ {
this.labelMooringETAETDValue.Content = "- / "; this.labelMooringETAETDValue.Content = "- / ";
this.textBlockMooringRemarks.Text = ""; this.textBlockMooringRemarks.Text = "";
this.imageMooringLocked.Visibility = Visibility.Hidden;
} }
Times? portAuthorityTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.PORT_ADMINISTRATION); Times? portAuthorityTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.PORT_ADMINISTRATION);
@ -350,11 +356,13 @@ namespace BreCalClient
{ {
this.labelPortAuthorityETAETDValue.Content = portAuthorityTimes.EtdBerth.HasValue ? portAuthorityTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -"; 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 else
{ {
this.labelPortAuthorityETAETDValue.Content = "- / -"; this.labelPortAuthorityETAETDValue.Content = "- / -";
this.textBlockPortAuthorityRemarks.Text = ""; this.textBlockPortAuthorityRemarks.Text = "";
this.imagePortAuthorityLocked.Visibility = Visibility.Hidden;
} }
Times? pilotTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.PILOT); Times? pilotTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.PILOT);
@ -366,11 +374,13 @@ namespace BreCalClient
{ {
this.labelPilotETAETDValue.Content = pilotTimes.EtdBerth.HasValue ? pilotTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -"; 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 else
{ {
this.labelPilotETAETDValue.Content = "- / -"; this.labelPilotETAETDValue.Content = "- / -";
this.textBlockPilotRemarks.Text = ""; this.textBlockPilotRemarks.Text = "";
this.imagePilotLocked.Visibility = Visibility.Hidden;
} }
Times? tugTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.TUG); Times? tugTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.TUG);
@ -382,11 +392,13 @@ namespace BreCalClient
{ {
this.labelTugETAETDValue.Content = tugTimes.EtdBerth.HasValue ? tugTimes.EtdBerth.Value.ToString("dd.MM.yyyy HH:mm") : "- / -"; 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 else
{ {
this.labelTugETAETDValue.Content = "- / -"; this.labelTugETAETDValue.Content = "- / -";
this.textBlockTugRemarks.Text = ""; this.textBlockTugRemarks.Text = "";
this.imageTugLocked.Visibility = Visibility.Hidden;
} }
Times? terminalTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.TERMINAL); Times? terminalTimes = this.ShipcallControlModel?.GetTimesForParticipantType(Extensions.ParticipantType.TERMINAL);