diff --git a/misc/BreCalApi.cs b/misc/BreCalApi.cs
index e1c100f..cc51180 100644
--- a/misc/BreCalApi.cs
+++ b/misc/BreCalApi.cs
@@ -1,7 +1,7 @@
//----------------------
//
-// Generated REST API Client Code Generator v1.9.8.0 on 28.03.2024 07:39:45
+// Generated REST API Client Code Generator v1.9.8.0 on 31.03.2024 21:55:59
// Using the tool OpenAPI Generator v7.4.0
//
//----------------------
@@ -4879,7 +4879,7 @@ namespace BreCalClient.misc.Client
///
/// Gets or sets the base path for API access.
///
- public virtual string BasePath
+ public virtual string BasePath
{
get { return _basePath; }
set { _basePath = value; }
@@ -6162,7 +6162,7 @@ namespace BreCalClient.misc.Model
/// Ship berth used for a ship call
///
[DataContract(Name = "berth")]
- public partial class Berth : IValidatableObject
+ public partial class Berth : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -6257,6 +6257,104 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as Berth);
+ }
+ ///
+ /// Returns true if Berth instances are equal
+ ///
+ /// Instance of Berth to be compared
+ /// Boolean
+ public bool Equals(Berth input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Id == input.Id ||
+ this.Id.Equals(input.Id)
+ ) &&
+ (
+ this.Name == input.Name ||
+ (this.Name != null &&
+ this.Name.Equals(input.Name))
+ ) &&
+ (
+ this.OwnerId == input.OwnerId ||
+ (this.OwnerId != null &&
+ this.OwnerId.Equals(input.OwnerId))
+ ) &&
+ (
+ this.AuthorityId == input.AuthorityId ||
+ (this.AuthorityId != null &&
+ this.AuthorityId.Equals(input.AuthorityId))
+ ) &&
+ (
+ this.VarLock == input.VarLock ||
+ (this.VarLock != null &&
+ this.VarLock.Equals(input.VarLock))
+ ) &&
+ (
+ this.Created == input.Created ||
+ (this.Created != null &&
+ this.Created.Equals(input.Created))
+ ) &&
+ (
+ this.Modified == input.Modified ||
+ (this.Modified != null &&
+ this.Modified.Equals(input.Modified))
+ ) &&
+ (
+ this.Deleted == input.Deleted ||
+ this.Deleted.Equals(input.Deleted)
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.Id.GetHashCode();
+ if (this.Name != null)
+ {
+ hashCode = (hashCode * 59) + this.Name.GetHashCode();
+ }
+ if (this.OwnerId != null)
+ {
+ hashCode = (hashCode * 59) + this.OwnerId.GetHashCode();
+ }
+ if (this.AuthorityId != null)
+ {
+ hashCode = (hashCode * 59) + this.AuthorityId.GetHashCode();
+ }
+ if (this.VarLock != null)
+ {
+ hashCode = (hashCode * 59) + this.VarLock.GetHashCode();
+ }
+ if (this.Created != null)
+ {
+ hashCode = (hashCode * 59) + this.Created.GetHashCode();
+ }
+ if (this.Modified != null)
+ {
+ hashCode = (hashCode * 59) + this.Modified.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.Deleted.GetHashCode();
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -6288,7 +6386,7 @@ namespace BreCalClient.misc.Model
/// Credentials
///
[DataContract(Name = "credentials")]
- public partial class Credentials : IValidatableObject
+ public partial class Credentials : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -6347,6 +6445,58 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as Credentials);
+ }
+ ///
+ /// Returns true if Credentials instances are equal
+ ///
+ /// Instance of Credentials to be compared
+ /// Boolean
+ public bool Equals(Credentials input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Username == input.Username ||
+ (this.Username != null &&
+ this.Username.Equals(input.Username))
+ ) &&
+ (
+ this.Password == input.Password ||
+ (this.Password != null &&
+ this.Password.Equals(input.Password))
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ if (this.Username != null)
+ {
+ hashCode = (hashCode * 59) + this.Username.GetHashCode();
+ }
+ if (this.Password != null)
+ {
+ hashCode = (hashCode * 59) + this.Password.GetHashCode();
+ }
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -6373,7 +6523,7 @@ namespace BreCalClient.misc.Model
/// Error
///
[DataContract(Name = "Error")]
- public partial class Error : IValidatableObject
+ public partial class Error : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -6420,6 +6570,49 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as Error);
+ }
+ ///
+ /// Returns true if Error instances are equal
+ ///
+ /// Instance of Error to be compared
+ /// Boolean
+ public bool Equals(Error input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Message == input.Message ||
+ (this.Message != null &&
+ this.Message.Equals(input.Message))
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ if (this.Message != null)
+ {
+ hashCode = (hashCode * 59) + this.Message.GetHashCode();
+ }
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -6486,7 +6679,7 @@ namespace BreCalClient.misc.Model
/// Single history entry with references
///
[DataContract(Name = "history")]
- public partial class History : IValidatableObject
+ public partial class History : IEquatable, IValidatableObject
{
///
/// Gets or Sets Operation
@@ -6570,6 +6763,83 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as History);
+ }
+ ///
+ /// Returns true if History instances are equal
+ ///
+ /// Instance of History to be compared
+ /// Boolean
+ public bool Equals(History input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Id == input.Id ||
+ this.Id.Equals(input.Id)
+ ) &&
+ (
+ this.ParticipantId == input.ParticipantId ||
+ this.ParticipantId.Equals(input.ParticipantId)
+ ) &&
+ (
+ this.ShipcallId == input.ShipcallId ||
+ this.ShipcallId.Equals(input.ShipcallId)
+ ) &&
+ (
+ this.Timestamp == input.Timestamp ||
+ (this.Timestamp != null &&
+ this.Timestamp.Equals(input.Timestamp))
+ ) &&
+ (
+ this.Eta == input.Eta ||
+ (this.Eta != null &&
+ this.Eta.Equals(input.Eta))
+ ) &&
+ (
+ this.Operation == input.Operation ||
+ this.Operation.Equals(input.Operation)
+ ) &&
+ (
+ this.Type == input.Type ||
+ this.Type.Equals(input.Type)
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.Id.GetHashCode();
+ hashCode = (hashCode * 59) + this.ParticipantId.GetHashCode();
+ hashCode = (hashCode * 59) + this.ShipcallId.GetHashCode();
+ if (this.Timestamp != null)
+ {
+ hashCode = (hashCode * 59) + this.Timestamp.GetHashCode();
+ }
+ if (this.Eta != null)
+ {
+ hashCode = (hashCode * 59) + this.Eta.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.Operation.GetHashCode();
+ hashCode = (hashCode * 59) + this.Type.GetHashCode();
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -6596,7 +6866,7 @@ namespace BreCalClient.misc.Model
/// A unique identifier for an entity
///
[DataContract(Name = "Id")]
- public partial class Id : IValidatableObject
+ public partial class Id : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -6632,6 +6902,45 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as Id);
+ }
+ ///
+ /// Returns true if Id instances are equal
+ ///
+ /// Instance of Id to be compared
+ /// Boolean
+ public bool Equals(Id input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.VarId == input.VarId ||
+ this.VarId.Equals(input.VarId)
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.VarId.GetHashCode();
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -6658,7 +6967,7 @@ namespace BreCalClient.misc.Model
/// result structure of a successful login attempt
///
[DataContract(Name = "login_result")]
- public partial class LoginResult : IValidatableObject
+ public partial class LoginResult : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -6758,6 +7067,109 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as LoginResult);
+ }
+ ///
+ /// Returns true if LoginResult instances are equal
+ ///
+ /// Instance of LoginResult to be compared
+ /// Boolean
+ public bool Equals(LoginResult input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Id == input.Id ||
+ this.Id.Equals(input.Id)
+ ) &&
+ (
+ this.ParticipantId == input.ParticipantId ||
+ this.ParticipantId.Equals(input.ParticipantId)
+ ) &&
+ (
+ this.FirstName == input.FirstName ||
+ (this.FirstName != null &&
+ this.FirstName.Equals(input.FirstName))
+ ) &&
+ (
+ this.LastName == input.LastName ||
+ (this.LastName != null &&
+ this.LastName.Equals(input.LastName))
+ ) &&
+ (
+ this.UserName == input.UserName ||
+ (this.UserName != null &&
+ this.UserName.Equals(input.UserName))
+ ) &&
+ (
+ this.UserPhone == input.UserPhone ||
+ (this.UserPhone != null &&
+ this.UserPhone.Equals(input.UserPhone))
+ ) &&
+ (
+ this.UserEmail == input.UserEmail ||
+ (this.UserEmail != null &&
+ this.UserEmail.Equals(input.UserEmail))
+ ) &&
+ (
+ this.Exp == input.Exp ||
+ this.Exp.Equals(input.Exp)
+ ) &&
+ (
+ this.Token == input.Token ||
+ (this.Token != null &&
+ this.Token.Equals(input.Token))
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.Id.GetHashCode();
+ hashCode = (hashCode * 59) + this.ParticipantId.GetHashCode();
+ if (this.FirstName != null)
+ {
+ hashCode = (hashCode * 59) + this.FirstName.GetHashCode();
+ }
+ if (this.LastName != null)
+ {
+ hashCode = (hashCode * 59) + this.LastName.GetHashCode();
+ }
+ if (this.UserName != null)
+ {
+ hashCode = (hashCode * 59) + this.UserName.GetHashCode();
+ }
+ if (this.UserPhone != null)
+ {
+ hashCode = (hashCode * 59) + this.UserPhone.GetHashCode();
+ }
+ if (this.UserEmail != null)
+ {
+ hashCode = (hashCode * 59) + this.UserEmail.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.Exp.GetHashCode();
+ if (this.Token != null)
+ {
+ hashCode = (hashCode * 59) + this.Token.GetHashCode();
+ }
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -6784,7 +7196,7 @@ namespace BreCalClient.misc.Model
/// a notification created by the engine if a times entry violates a rule
///
[DataContract(Name = "notification")]
- public partial class Notification : IValidatableObject
+ public partial class Notification : IEquatable, IValidatableObject
{
///
/// Gets or Sets NotificationType
@@ -6862,6 +7274,82 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as Notification);
+ }
+ ///
+ /// Returns true if Notification instances are equal
+ ///
+ /// Instance of Notification to be compared
+ /// Boolean
+ public bool Equals(Notification input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Id == input.Id ||
+ this.Id.Equals(input.Id)
+ ) &&
+ (
+ this.ShipcallId == input.ShipcallId ||
+ this.ShipcallId.Equals(input.ShipcallId)
+ ) &&
+ (
+ this.NotificationType == input.NotificationType ||
+ this.NotificationType.Equals(input.NotificationType)
+ ) &&
+ (
+ this.Message == input.Message ||
+ (this.Message != null &&
+ this.Message.Equals(input.Message))
+ ) &&
+ (
+ this.Created == input.Created ||
+ (this.Created != null &&
+ this.Created.Equals(input.Created))
+ ) &&
+ (
+ this.Modified == input.Modified ||
+ (this.Modified != null &&
+ this.Modified.Equals(input.Modified))
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.Id.GetHashCode();
+ hashCode = (hashCode * 59) + this.ShipcallId.GetHashCode();
+ hashCode = (hashCode * 59) + this.NotificationType.GetHashCode();
+ if (this.Message != null)
+ {
+ hashCode = (hashCode * 59) + this.Message.GetHashCode();
+ }
+ if (this.Created != null)
+ {
+ hashCode = (hashCode * 59) + this.Created.GetHashCode();
+ }
+ if (this.Modified != null)
+ {
+ hashCode = (hashCode * 59) + this.Modified.GetHashCode();
+ }
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -6993,7 +7481,7 @@ namespace BreCalClient.misc.Model
/// A organisational entity that participates in Bremen Calling
///
[DataContract(Name = "participant")]
- public partial class Participant : IValidatableObject
+ public partial class Participant : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -7104,6 +7592,118 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as Participant);
+ }
+ ///
+ /// Returns true if Participant instances are equal
+ ///
+ /// Instance of Participant to be compared
+ /// Boolean
+ public bool Equals(Participant input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Id == input.Id ||
+ this.Id.Equals(input.Id)
+ ) &&
+ (
+ this.Name == input.Name ||
+ (this.Name != null &&
+ this.Name.Equals(input.Name))
+ ) &&
+ (
+ this.Street == input.Street ||
+ (this.Street != null &&
+ this.Street.Equals(input.Street))
+ ) &&
+ (
+ this.PostalCode == input.PostalCode ||
+ (this.PostalCode != null &&
+ this.PostalCode.Equals(input.PostalCode))
+ ) &&
+ (
+ this.City == input.City ||
+ (this.City != null &&
+ this.City.Equals(input.City))
+ ) &&
+ (
+ this.Type == input.Type ||
+ this.Type.Equals(input.Type)
+ ) &&
+ (
+ this.Flags == input.Flags ||
+ (this.Flags != null &&
+ this.Flags.Equals(input.Flags))
+ ) &&
+ (
+ this.Created == input.Created ||
+ (this.Created != null &&
+ this.Created.Equals(input.Created))
+ ) &&
+ (
+ this.Modified == input.Modified ||
+ (this.Modified != null &&
+ this.Modified.Equals(input.Modified))
+ ) &&
+ (
+ this.Deleted == input.Deleted ||
+ this.Deleted.Equals(input.Deleted)
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.Id.GetHashCode();
+ if (this.Name != null)
+ {
+ hashCode = (hashCode * 59) + this.Name.GetHashCode();
+ }
+ if (this.Street != null)
+ {
+ hashCode = (hashCode * 59) + this.Street.GetHashCode();
+ }
+ if (this.PostalCode != null)
+ {
+ hashCode = (hashCode * 59) + this.PostalCode.GetHashCode();
+ }
+ if (this.City != null)
+ {
+ hashCode = (hashCode * 59) + this.City.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.Type.GetHashCode();
+ if (this.Flags != null)
+ {
+ hashCode = (hashCode * 59) + this.Flags.GetHashCode();
+ }
+ if (this.Created != null)
+ {
+ hashCode = (hashCode * 59) + this.Created.GetHashCode();
+ }
+ if (this.Modified != null)
+ {
+ hashCode = (hashCode * 59) + this.Modified.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.Deleted.GetHashCode();
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -7150,7 +7750,7 @@ namespace BreCalClient.misc.Model
/// Participant assigned to a shipcall with a given role (type)
///
[DataContract(Name = "participant_assignment")]
- public partial class ParticipantAssignment : IValidatableObject
+ public partial class ParticipantAssignment : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -7200,6 +7800,50 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as ParticipantAssignment);
+ }
+ ///
+ /// Returns true if ParticipantAssignment instances are equal
+ ///
+ /// Instance of ParticipantAssignment to be compared
+ /// Boolean
+ public bool Equals(ParticipantAssignment input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.ParticipantId == input.ParticipantId ||
+ this.ParticipantId.Equals(input.ParticipantId)
+ ) &&
+ (
+ this.Type == input.Type ||
+ this.Type.Equals(input.Type)
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.ParticipantId.GetHashCode();
+ hashCode = (hashCode * 59) + this.Type.GetHashCode();
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -7226,7 +7870,7 @@ namespace BreCalClient.misc.Model
/// a ship
///
[DataContract(Name = "ship")]
- public partial class Ship : IValidatableObject
+ public partial class Ship : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -7360,6 +8004,145 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as Ship);
+ }
+ ///
+ /// Returns true if Ship instances are equal
+ ///
+ /// Instance of Ship to be compared
+ /// Boolean
+ public bool Equals(Ship input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Id == input.Id ||
+ this.Id.Equals(input.Id)
+ ) &&
+ (
+ this.Name == input.Name ||
+ (this.Name != null &&
+ this.Name.Equals(input.Name))
+ ) &&
+ (
+ this.Imo == input.Imo ||
+ (this.Imo != null &&
+ this.Imo.Equals(input.Imo))
+ ) &&
+ (
+ this.Callsign == input.Callsign ||
+ (this.Callsign != null &&
+ this.Callsign.Equals(input.Callsign))
+ ) &&
+ (
+ this.ParticipantId == input.ParticipantId ||
+ (this.ParticipantId != null &&
+ this.ParticipantId.Equals(input.ParticipantId))
+ ) &&
+ (
+ this.Length == input.Length ||
+ (this.Length != null &&
+ this.Length.Equals(input.Length))
+ ) &&
+ (
+ this.Width == input.Width ||
+ (this.Width != null &&
+ this.Width.Equals(input.Width))
+ ) &&
+ (
+ this.IsTug == input.IsTug ||
+ this.IsTug.Equals(input.IsTug)
+ ) &&
+ (
+ this.BollardPull == input.BollardPull ||
+ (this.BollardPull != null &&
+ this.BollardPull.Equals(input.BollardPull))
+ ) &&
+ (
+ this.Eni == input.Eni ||
+ (this.Eni != null &&
+ this.Eni.Equals(input.Eni))
+ ) &&
+ (
+ this.Created == input.Created ||
+ (this.Created != null &&
+ this.Created.Equals(input.Created))
+ ) &&
+ (
+ this.Modified == input.Modified ||
+ (this.Modified != null &&
+ this.Modified.Equals(input.Modified))
+ ) &&
+ (
+ this.Deleted == input.Deleted ||
+ this.Deleted.Equals(input.Deleted)
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.Id.GetHashCode();
+ if (this.Name != null)
+ {
+ hashCode = (hashCode * 59) + this.Name.GetHashCode();
+ }
+ if (this.Imo != null)
+ {
+ hashCode = (hashCode * 59) + this.Imo.GetHashCode();
+ }
+ if (this.Callsign != null)
+ {
+ hashCode = (hashCode * 59) + this.Callsign.GetHashCode();
+ }
+ if (this.ParticipantId != null)
+ {
+ hashCode = (hashCode * 59) + this.ParticipantId.GetHashCode();
+ }
+ if (this.Length != null)
+ {
+ hashCode = (hashCode * 59) + this.Length.GetHashCode();
+ }
+ if (this.Width != null)
+ {
+ hashCode = (hashCode * 59) + this.Width.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.IsTug.GetHashCode();
+ if (this.BollardPull != null)
+ {
+ hashCode = (hashCode * 59) + this.BollardPull.GetHashCode();
+ }
+ if (this.Eni != null)
+ {
+ hashCode = (hashCode * 59) + this.Eni.GetHashCode();
+ }
+ if (this.Created != null)
+ {
+ hashCode = (hashCode * 59) + this.Created.GetHashCode();
+ }
+ if (this.Modified != null)
+ {
+ hashCode = (hashCode * 59) + this.Modified.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.Deleted.GetHashCode();
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -7396,7 +8179,7 @@ namespace BreCalClient.misc.Model
/// Shipcall
///
[DataContract(Name = "shipcall")]
- public partial class Shipcall : IValidatableObject
+ public partial class Shipcall : IEquatable, IValidatableObject
{
///
/// Gets or Sets Type
@@ -7665,6 +8448,286 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as Shipcall);
+ }
+ ///
+ /// Returns true if Shipcall instances are equal
+ ///
+ /// Instance of Shipcall to be compared
+ /// Boolean
+ public bool Equals(Shipcall input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Id == input.Id ||
+ this.Id.Equals(input.Id)
+ ) &&
+ (
+ this.ShipId == input.ShipId ||
+ this.ShipId.Equals(input.ShipId)
+ ) &&
+ (
+ this.Type == input.Type ||
+ this.Type.Equals(input.Type)
+ ) &&
+ (
+ this.Eta == input.Eta ||
+ (this.Eta != null &&
+ this.Eta.Equals(input.Eta))
+ ) &&
+ (
+ this.Voyage == input.Voyage ||
+ (this.Voyage != null &&
+ this.Voyage.Equals(input.Voyage))
+ ) &&
+ (
+ this.Etd == input.Etd ||
+ (this.Etd != null &&
+ this.Etd.Equals(input.Etd))
+ ) &&
+ (
+ this.ArrivalBerthId == input.ArrivalBerthId ||
+ (this.ArrivalBerthId != null &&
+ this.ArrivalBerthId.Equals(input.ArrivalBerthId))
+ ) &&
+ (
+ this.DepartureBerthId == input.DepartureBerthId ||
+ (this.DepartureBerthId != null &&
+ this.DepartureBerthId.Equals(input.DepartureBerthId))
+ ) &&
+ (
+ this.TugRequired == input.TugRequired ||
+ (this.TugRequired != null &&
+ this.TugRequired.Equals(input.TugRequired))
+ ) &&
+ (
+ this.PilotRequired == input.PilotRequired ||
+ (this.PilotRequired != null &&
+ this.PilotRequired.Equals(input.PilotRequired))
+ ) &&
+ (
+ this.Flags == input.Flags ||
+ (this.Flags != null &&
+ this.Flags.Equals(input.Flags))
+ ) &&
+ (
+ this.PierSide == input.PierSide ||
+ (this.PierSide != null &&
+ this.PierSide.Equals(input.PierSide))
+ ) &&
+ (
+ this.Bunkering == input.Bunkering ||
+ (this.Bunkering != null &&
+ this.Bunkering.Equals(input.Bunkering))
+ ) &&
+ (
+ this.ReplenishingTerminal == input.ReplenishingTerminal ||
+ (this.ReplenishingTerminal != null &&
+ this.ReplenishingTerminal.Equals(input.ReplenishingTerminal))
+ ) &&
+ (
+ this.ReplenishingLock == input.ReplenishingLock ||
+ (this.ReplenishingLock != null &&
+ this.ReplenishingLock.Equals(input.ReplenishingLock))
+ ) &&
+ (
+ this.Draft == input.Draft ||
+ (this.Draft != null &&
+ this.Draft.Equals(input.Draft))
+ ) &&
+ (
+ this.TidalWindowFrom == input.TidalWindowFrom ||
+ (this.TidalWindowFrom != null &&
+ this.TidalWindowFrom.Equals(input.TidalWindowFrom))
+ ) &&
+ (
+ this.TidalWindowTo == input.TidalWindowTo ||
+ (this.TidalWindowTo != null &&
+ this.TidalWindowTo.Equals(input.TidalWindowTo))
+ ) &&
+ (
+ this.RainSensitiveCargo == input.RainSensitiveCargo ||
+ (this.RainSensitiveCargo != null &&
+ this.RainSensitiveCargo.Equals(input.RainSensitiveCargo))
+ ) &&
+ (
+ this.RecommendedTugs == input.RecommendedTugs ||
+ (this.RecommendedTugs != null &&
+ this.RecommendedTugs.Equals(input.RecommendedTugs))
+ ) &&
+ (
+ this.Anchored == input.Anchored ||
+ (this.Anchored != null &&
+ this.Anchored.Equals(input.Anchored))
+ ) &&
+ (
+ this.MooredLock == input.MooredLock ||
+ (this.MooredLock != null &&
+ this.MooredLock.Equals(input.MooredLock))
+ ) &&
+ (
+ this.Canceled == input.Canceled ||
+ (this.Canceled != null &&
+ this.Canceled.Equals(input.Canceled))
+ ) &&
+ (
+ this.Evaluation == input.Evaluation ||
+ this.Evaluation.Equals(input.Evaluation)
+ ) &&
+ (
+ this.EvaluationMessage == input.EvaluationMessage ||
+ (this.EvaluationMessage != null &&
+ this.EvaluationMessage.Equals(input.EvaluationMessage))
+ ) &&
+ (
+ this.TimeRefPoint == input.TimeRefPoint ||
+ (this.TimeRefPoint != null &&
+ this.TimeRefPoint.Equals(input.TimeRefPoint))
+ ) &&
+ (
+ this.Participants == input.Participants ||
+ this.Participants != null &&
+ input.Participants != null &&
+ this.Participants.SequenceEqual(input.Participants)
+ ) &&
+ (
+ this.Created == input.Created ||
+ (this.Created != null &&
+ this.Created.Equals(input.Created))
+ ) &&
+ (
+ this.Modified == input.Modified ||
+ (this.Modified != null &&
+ this.Modified.Equals(input.Modified))
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.Id.GetHashCode();
+ hashCode = (hashCode * 59) + this.ShipId.GetHashCode();
+ hashCode = (hashCode * 59) + this.Type.GetHashCode();
+ if (this.Eta != null)
+ {
+ hashCode = (hashCode * 59) + this.Eta.GetHashCode();
+ }
+ if (this.Voyage != null)
+ {
+ hashCode = (hashCode * 59) + this.Voyage.GetHashCode();
+ }
+ if (this.Etd != null)
+ {
+ hashCode = (hashCode * 59) + this.Etd.GetHashCode();
+ }
+ if (this.ArrivalBerthId != null)
+ {
+ hashCode = (hashCode * 59) + this.ArrivalBerthId.GetHashCode();
+ }
+ if (this.DepartureBerthId != null)
+ {
+ hashCode = (hashCode * 59) + this.DepartureBerthId.GetHashCode();
+ }
+ if (this.TugRequired != null)
+ {
+ hashCode = (hashCode * 59) + this.TugRequired.GetHashCode();
+ }
+ if (this.PilotRequired != null)
+ {
+ hashCode = (hashCode * 59) + this.PilotRequired.GetHashCode();
+ }
+ if (this.Flags != null)
+ {
+ hashCode = (hashCode * 59) + this.Flags.GetHashCode();
+ }
+ if (this.PierSide != null)
+ {
+ hashCode = (hashCode * 59) + this.PierSide.GetHashCode();
+ }
+ if (this.Bunkering != null)
+ {
+ hashCode = (hashCode * 59) + this.Bunkering.GetHashCode();
+ }
+ if (this.ReplenishingTerminal != null)
+ {
+ hashCode = (hashCode * 59) + this.ReplenishingTerminal.GetHashCode();
+ }
+ if (this.ReplenishingLock != null)
+ {
+ hashCode = (hashCode * 59) + this.ReplenishingLock.GetHashCode();
+ }
+ if (this.Draft != null)
+ {
+ hashCode = (hashCode * 59) + this.Draft.GetHashCode();
+ }
+ if (this.TidalWindowFrom != null)
+ {
+ hashCode = (hashCode * 59) + this.TidalWindowFrom.GetHashCode();
+ }
+ if (this.TidalWindowTo != null)
+ {
+ hashCode = (hashCode * 59) + this.TidalWindowTo.GetHashCode();
+ }
+ if (this.RainSensitiveCargo != null)
+ {
+ hashCode = (hashCode * 59) + this.RainSensitiveCargo.GetHashCode();
+ }
+ if (this.RecommendedTugs != null)
+ {
+ hashCode = (hashCode * 59) + this.RecommendedTugs.GetHashCode();
+ }
+ if (this.Anchored != null)
+ {
+ hashCode = (hashCode * 59) + this.Anchored.GetHashCode();
+ }
+ if (this.MooredLock != null)
+ {
+ hashCode = (hashCode * 59) + this.MooredLock.GetHashCode();
+ }
+ if (this.Canceled != null)
+ {
+ hashCode = (hashCode * 59) + this.Canceled.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.Evaluation.GetHashCode();
+ if (this.EvaluationMessage != null)
+ {
+ hashCode = (hashCode * 59) + this.EvaluationMessage.GetHashCode();
+ }
+ if (this.TimeRefPoint != null)
+ {
+ hashCode = (hashCode * 59) + this.TimeRefPoint.GetHashCode();
+ }
+ if (this.Participants != null)
+ {
+ hashCode = (hashCode * 59) + this.Participants.GetHashCode();
+ }
+ if (this.Created != null)
+ {
+ hashCode = (hashCode * 59) + this.Created.GetHashCode();
+ }
+ if (this.Modified != null)
+ {
+ hashCode = (hashCode * 59) + this.Modified.GetHashCode();
+ }
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -7741,7 +8804,7 @@ namespace BreCalClient.misc.Model
/// the id parameter needs to be missing on POST and to be present on PUT (Update) calls, otherwise a 400 response will be generated
///
[DataContract(Name = "times")]
- public partial class Times : IValidatableObject
+ public partial class Times : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -7769,11 +8832,12 @@ namespace BreCalClient.misc.Model
/// Additional info text for berth.
/// true if ship is rotated, false otherwise.
/// participantType.
- /// can be set by mooring if actual times are different from planned.
+ /// can be set by mooring if actual times are different from planned.
+ /// can be set by mooring if actual times are different from planned.
/// End of the interval for the times entry.
/// Readonly field set by the database.
/// Readonly field set by the database.
- public Times(int id = default(int), DateTime? etaBerth = default(DateTime?), bool? etaBerthFixed = default(bool?), DateTime? etdBerth = default(DateTime?), bool? etdBerthFixed = default(bool?), DateTime? lockTime = default(DateTime?), bool? lockTimeFixed = default(bool?), DateTime? zoneEntry = default(DateTime?), bool? zoneEntryFixed = default(bool?), DateTime? operationsStart = default(DateTime?), DateTime? operationsEnd = default(DateTime?), string remarks = default(string), int shipcallId = default(int), int participantId = default(int), int? berthId = default(int?), string berthInfo = default(string), bool? pierSide = default(bool?), int participantType = default(int), DateTime? ataAtd = default(DateTime?), DateTime? intervalEnd = default(DateTime?), DateTime created = default(DateTime), DateTime? modified = default(DateTime?))
+ public Times(int id = default(int), DateTime? etaBerth = default(DateTime?), bool? etaBerthFixed = default(bool?), DateTime? etdBerth = default(DateTime?), bool? etdBerthFixed = default(bool?), DateTime? lockTime = default(DateTime?), bool? lockTimeFixed = default(bool?), DateTime? zoneEntry = default(DateTime?), bool? zoneEntryFixed = default(bool?), DateTime? operationsStart = default(DateTime?), DateTime? operationsEnd = default(DateTime?), string remarks = default(string), int shipcallId = default(int), int participantId = default(int), int? berthId = default(int?), string berthInfo = default(string), bool? pierSide = default(bool?), int participantType = default(int), DateTime? ata = default(DateTime?), DateTime? atd = default(DateTime?), DateTime? intervalEnd = default(DateTime?), DateTime created = default(DateTime), DateTime? modified = default(DateTime?))
{
this.ShipcallId = shipcallId;
this.ParticipantId = participantId;
@@ -7793,7 +8857,8 @@ namespace BreCalClient.misc.Model
this.BerthInfo = berthInfo;
this.PierSide = pierSide;
this.ParticipantType = participantType;
- this.AtaAtd = ataAtd;
+ this.Ata = ata;
+ this.Atd = atd;
this.IntervalEnd = intervalEnd;
this.Created = created;
this.Modified = modified;
@@ -7907,8 +8972,14 @@ namespace BreCalClient.misc.Model
/// can be set by mooring if actual times are different from planned
///
/// can be set by mooring if actual times are different from planned
- [DataMember(Name = "ata_atd", EmitDefaultValue = true)]
- public DateTime? AtaAtd { get; set; }
+ [DataMember(Name = "ata", EmitDefaultValue = true)]
+ public DateTime? Ata { get; set; }
+ ///
+ /// can be set by mooring if actual times are different from planned
+ ///
+ /// can be set by mooring if actual times are different from planned
+ [DataMember(Name = "atd", EmitDefaultValue = true)]
+ public DateTime? Atd { get; set; }
///
/// End of the interval for the times entry
///
@@ -7953,7 +9024,8 @@ namespace BreCalClient.misc.Model
sb.Append(" BerthInfo: ").Append(BerthInfo).Append("\n");
sb.Append(" PierSide: ").Append(PierSide).Append("\n");
sb.Append(" ParticipantType: ").Append(ParticipantType).Append("\n");
- sb.Append(" AtaAtd: ").Append(AtaAtd).Append("\n");
+ sb.Append(" Ata: ").Append(Ata).Append("\n");
+ sb.Append(" Atd: ").Append(Atd).Append("\n");
sb.Append(" IntervalEnd: ").Append(IntervalEnd).Append("\n");
sb.Append(" Created: ").Append(Created).Append("\n");
sb.Append(" Modified: ").Append(Modified).Append("\n");
@@ -7969,6 +9041,231 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as Times);
+ }
+ ///
+ /// Returns true if Times instances are equal
+ ///
+ /// Instance of Times to be compared
+ /// Boolean
+ public bool Equals(Times input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Id == input.Id ||
+ this.Id.Equals(input.Id)
+ ) &&
+ (
+ this.EtaBerth == input.EtaBerth ||
+ (this.EtaBerth != null &&
+ this.EtaBerth.Equals(input.EtaBerth))
+ ) &&
+ (
+ this.EtaBerthFixed == input.EtaBerthFixed ||
+ (this.EtaBerthFixed != null &&
+ this.EtaBerthFixed.Equals(input.EtaBerthFixed))
+ ) &&
+ (
+ this.EtdBerth == input.EtdBerth ||
+ (this.EtdBerth != null &&
+ this.EtdBerth.Equals(input.EtdBerth))
+ ) &&
+ (
+ this.EtdBerthFixed == input.EtdBerthFixed ||
+ (this.EtdBerthFixed != null &&
+ this.EtdBerthFixed.Equals(input.EtdBerthFixed))
+ ) &&
+ (
+ this.LockTime == input.LockTime ||
+ (this.LockTime != null &&
+ this.LockTime.Equals(input.LockTime))
+ ) &&
+ (
+ this.LockTimeFixed == input.LockTimeFixed ||
+ (this.LockTimeFixed != null &&
+ this.LockTimeFixed.Equals(input.LockTimeFixed))
+ ) &&
+ (
+ this.ZoneEntry == input.ZoneEntry ||
+ (this.ZoneEntry != null &&
+ this.ZoneEntry.Equals(input.ZoneEntry))
+ ) &&
+ (
+ this.ZoneEntryFixed == input.ZoneEntryFixed ||
+ (this.ZoneEntryFixed != null &&
+ this.ZoneEntryFixed.Equals(input.ZoneEntryFixed))
+ ) &&
+ (
+ this.OperationsStart == input.OperationsStart ||
+ (this.OperationsStart != null &&
+ this.OperationsStart.Equals(input.OperationsStart))
+ ) &&
+ (
+ this.OperationsEnd == input.OperationsEnd ||
+ (this.OperationsEnd != null &&
+ this.OperationsEnd.Equals(input.OperationsEnd))
+ ) &&
+ (
+ this.Remarks == input.Remarks ||
+ (this.Remarks != null &&
+ this.Remarks.Equals(input.Remarks))
+ ) &&
+ (
+ this.ShipcallId == input.ShipcallId ||
+ this.ShipcallId.Equals(input.ShipcallId)
+ ) &&
+ (
+ this.ParticipantId == input.ParticipantId ||
+ this.ParticipantId.Equals(input.ParticipantId)
+ ) &&
+ (
+ this.BerthId == input.BerthId ||
+ (this.BerthId != null &&
+ this.BerthId.Equals(input.BerthId))
+ ) &&
+ (
+ this.BerthInfo == input.BerthInfo ||
+ (this.BerthInfo != null &&
+ this.BerthInfo.Equals(input.BerthInfo))
+ ) &&
+ (
+ this.PierSide == input.PierSide ||
+ (this.PierSide != null &&
+ this.PierSide.Equals(input.PierSide))
+ ) &&
+ (
+ this.ParticipantType == input.ParticipantType ||
+ this.ParticipantType.Equals(input.ParticipantType)
+ ) &&
+ (
+ this.Ata == input.Ata ||
+ (this.Ata != null &&
+ this.Ata.Equals(input.Ata))
+ ) &&
+ (
+ this.Atd == input.Atd ||
+ (this.Atd != null &&
+ this.Atd.Equals(input.Atd))
+ ) &&
+ (
+ this.IntervalEnd == input.IntervalEnd ||
+ (this.IntervalEnd != null &&
+ this.IntervalEnd.Equals(input.IntervalEnd))
+ ) &&
+ (
+ this.Created == input.Created ||
+ (this.Created != null &&
+ this.Created.Equals(input.Created))
+ ) &&
+ (
+ this.Modified == input.Modified ||
+ (this.Modified != null &&
+ this.Modified.Equals(input.Modified))
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.Id.GetHashCode();
+ if (this.EtaBerth != null)
+ {
+ hashCode = (hashCode * 59) + this.EtaBerth.GetHashCode();
+ }
+ if (this.EtaBerthFixed != null)
+ {
+ hashCode = (hashCode * 59) + this.EtaBerthFixed.GetHashCode();
+ }
+ if (this.EtdBerth != null)
+ {
+ hashCode = (hashCode * 59) + this.EtdBerth.GetHashCode();
+ }
+ if (this.EtdBerthFixed != null)
+ {
+ hashCode = (hashCode * 59) + this.EtdBerthFixed.GetHashCode();
+ }
+ if (this.LockTime != null)
+ {
+ hashCode = (hashCode * 59) + this.LockTime.GetHashCode();
+ }
+ if (this.LockTimeFixed != null)
+ {
+ hashCode = (hashCode * 59) + this.LockTimeFixed.GetHashCode();
+ }
+ if (this.ZoneEntry != null)
+ {
+ hashCode = (hashCode * 59) + this.ZoneEntry.GetHashCode();
+ }
+ if (this.ZoneEntryFixed != null)
+ {
+ hashCode = (hashCode * 59) + this.ZoneEntryFixed.GetHashCode();
+ }
+ if (this.OperationsStart != null)
+ {
+ hashCode = (hashCode * 59) + this.OperationsStart.GetHashCode();
+ }
+ if (this.OperationsEnd != null)
+ {
+ hashCode = (hashCode * 59) + this.OperationsEnd.GetHashCode();
+ }
+ if (this.Remarks != null)
+ {
+ hashCode = (hashCode * 59) + this.Remarks.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.ShipcallId.GetHashCode();
+ hashCode = (hashCode * 59) + this.ParticipantId.GetHashCode();
+ if (this.BerthId != null)
+ {
+ hashCode = (hashCode * 59) + this.BerthId.GetHashCode();
+ }
+ if (this.BerthInfo != null)
+ {
+ hashCode = (hashCode * 59) + this.BerthInfo.GetHashCode();
+ }
+ if (this.PierSide != null)
+ {
+ hashCode = (hashCode * 59) + this.PierSide.GetHashCode();
+ }
+ hashCode = (hashCode * 59) + this.ParticipantType.GetHashCode();
+ if (this.Ata != null)
+ {
+ hashCode = (hashCode * 59) + this.Ata.GetHashCode();
+ }
+ if (this.Atd != null)
+ {
+ hashCode = (hashCode * 59) + this.Atd.GetHashCode();
+ }
+ if (this.IntervalEnd != null)
+ {
+ hashCode = (hashCode * 59) + this.IntervalEnd.GetHashCode();
+ }
+ if (this.Created != null)
+ {
+ hashCode = (hashCode * 59) + this.Created.GetHashCode();
+ }
+ if (this.Modified != null)
+ {
+ hashCode = (hashCode * 59) + this.Modified.GetHashCode();
+ }
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
@@ -8005,7 +9302,7 @@ namespace BreCalClient.misc.Model
/// fields that a user may change
///
[DataContract(Name = "user_details")]
- public partial class UserDetails : IValidatableObject
+ public partial class UserDetails : IEquatable, IValidatableObject
{
///
/// Initializes a new instance of the class.
@@ -8089,6 +9386,99 @@ namespace BreCalClient.misc.Model
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
///
+ /// Returns true if objects are equal
+ ///
+ /// Object to be compared
+ /// Boolean
+ public override bool Equals(object input)
+ {
+ return this.Equals(input as UserDetails);
+ }
+ ///
+ /// Returns true if UserDetails instances are equal
+ ///
+ /// Instance of UserDetails to be compared
+ /// Boolean
+ public bool Equals(UserDetails input)
+ {
+ if (input == null)
+ {
+ return false;
+ }
+ return
+ (
+ this.Id == input.Id ||
+ this.Id.Equals(input.Id)
+ ) &&
+ (
+ this.OldPassword == input.OldPassword ||
+ (this.OldPassword != null &&
+ this.OldPassword.Equals(input.OldPassword))
+ ) &&
+ (
+ this.NewPassword == input.NewPassword ||
+ (this.NewPassword != null &&
+ this.NewPassword.Equals(input.NewPassword))
+ ) &&
+ (
+ this.FirstName == input.FirstName ||
+ (this.FirstName != null &&
+ this.FirstName.Equals(input.FirstName))
+ ) &&
+ (
+ this.LastName == input.LastName ||
+ (this.LastName != null &&
+ this.LastName.Equals(input.LastName))
+ ) &&
+ (
+ this.UserPhone == input.UserPhone ||
+ (this.UserPhone != null &&
+ this.UserPhone.Equals(input.UserPhone))
+ ) &&
+ (
+ this.UserEmail == input.UserEmail ||
+ (this.UserEmail != null &&
+ this.UserEmail.Equals(input.UserEmail))
+ );
+ }
+ ///
+ /// Gets the hash code
+ ///
+ /// Hash code
+ public override int GetHashCode()
+ {
+ unchecked // Overflow is fine, just wrap
+ {
+ int hashCode = 41;
+ hashCode = (hashCode * 59) + this.Id.GetHashCode();
+ if (this.OldPassword != null)
+ {
+ hashCode = (hashCode * 59) + this.OldPassword.GetHashCode();
+ }
+ if (this.NewPassword != null)
+ {
+ hashCode = (hashCode * 59) + this.NewPassword.GetHashCode();
+ }
+ if (this.FirstName != null)
+ {
+ hashCode = (hashCode * 59) + this.FirstName.GetHashCode();
+ }
+ if (this.LastName != null)
+ {
+ hashCode = (hashCode * 59) + this.LastName.GetHashCode();
+ }
+ if (this.UserPhone != null)
+ {
+ hashCode = (hashCode * 59) + this.UserPhone.GetHashCode();
+ }
+ if (this.UserEmail != null)
+ {
+ hashCode = (hashCode * 59) + this.UserEmail.GetHashCode();
+ }
+ return hashCode;
+ }
+ }
+ ///
/// To validate all properties of the instance
///
/// Validation context
diff --git a/misc/BreCalApi.yaml b/misc/BreCalApi.yaml
index fd767b0..4c4fb27 100644
--- a/misc/BreCalApi.yaml
+++ b/misc/BreCalApi.yaml
@@ -664,7 +664,12 @@ components:
nullable: true
participant_type:
type: integer
- ata_atd:
+ ata:
+ type: string
+ format: date-time
+ nullable: true
+ description: can be set by mooring if actual times are different from planned
+ atd:
type: string
format: date-time
nullable: true
diff --git a/misc/update_1.1_to_1.2.sql b/misc/update_1.1_to_1.2.sql
index d023c47..9fb7a80 100644
--- a/misc/update_1.1_to_1.2.sql
+++ b/misc/update_1.1_to_1.2.sql
@@ -86,8 +86,9 @@ ADD CONSTRAINT `FK_HISTORY_USER`
ON DELETE NO ACTION
ON UPDATE NO ACTION;
--- add ata_atd field to times
+-- add additional fields to times
ALTER TABLE `bremen_calling_devel`.`times`
-ADD COLUMN `ata_atd` DATETIME NULL DEFAULT NULL COMMENT 'Relevant only for mooring, this field can be used to record actual ATA / ATD' AFTER `participant_type`,
-ADD COLUMN `interval_end` DATETIME NULL DEFAULT NULL COMMENT 'If this value is set the times are given as interval instead of a single point in time. The start time value depends on the participant type.' AFTER `ata_atd`;
\ No newline at end of file
+ADD COLUMN `ata` DATETIME NULL DEFAULT NULL COMMENT 'Relevant only for mooring, this field can be used to record actual ATA' AFTER `participant_type`,
+ADD COLUMN `atd` DATETIME NULL DEFAULT NULL COMMENT 'Relevant only for mooring, this field can be used to record actual ATD' AFTER `ata`,
+ADD COLUMN `interval_end` DATETIME NULL DEFAULT NULL COMMENT 'If this value is set the times are given as interval instead of a single point in time. The start time value depends on the participant type.' AFTER `atd`;
\ No newline at end of file
diff --git a/src/server/BreCal/impl/times.py b/src/server/BreCal/impl/times.py
index ab4786d..3c22b4d 100644
--- a/src/server/BreCal/impl/times.py
+++ b/src/server/BreCal/impl/times.py
@@ -22,7 +22,7 @@ def GetTimes(options):
commands = pydapper.using(pooledConnection)
data = commands.query("SELECT id, eta_berth, eta_berth_fixed, etd_berth, etd_berth_fixed, lock_time, lock_time_fixed, " +
"zone_entry, zone_entry_fixed, operations_start, operations_end, remarks, shipcall_id, participant_id, " +
- "berth_id, berth_info, pier_side, participant_type, created, modified, ata_atd, interval_end FROM times " +
+ "berth_id, berth_info, pier_side, participant_type, created, modified, ata, atd, interval_end FROM times " +
"WHERE times.shipcall_id = ?scid?", model=model.Times, param={"scid" : options["shipcall_id"]})
pooledConnection.close()
diff --git a/src/server/BreCal/schemas/model.py b/src/server/BreCal/schemas/model.py
index beac9cb..29866d7 100644
--- a/src/server/BreCal/schemas/model.py
+++ b/src/server/BreCal/schemas/model.py
@@ -305,7 +305,8 @@ class TimesSchema(Schema):
pier_side = fields.Bool(Required = False, allow_none = True)
shipcall_id = fields.Int(Required = True)
participant_type = fields.Int(Required = False, allow_none=True)
- ata_atd = fields.DateTime(Required = False, allow_none=True)
+ ata = fields.DateTime(Required = False, allow_none=True)
+ atd = fields.DateTime(Required = False, allow_none=True)
interval_end = fields.DateTime(Required = False, allow_none=True)
created = fields.DateTime(Required = False, allow_none=True)
modified = fields.DateTime(Required = False, allow_none=True)
@@ -344,7 +345,8 @@ class Times:
pier_side: bool
participant_type: int
shipcall_id: int
- ata_atd: datetime
+ ata: datetime
+ atd: datetime
interval_end: datetime
created: datetime
modified: datetime