public int GetIdempotentKey()
 {
     unchecked
     {
         int hashCode = Currency?.GetHashCode() ?? 0;
         hashCode = (hashCode * 397) ^ DiscountAmount.GetHashCode();
         hashCode = (hashCode * 397) ^ LineItems.GetIdempotentListKey();
         hashCode = (hashCode * 397) ^ (Number?.GetHashCode() ?? 0);
         hashCode = (hashCode * 397) ^ TotalGrossAmount.GetHashCode();
         hashCode = (hashCode * 397) ^ TotalNetAmount.GetHashCode();
         return(hashCode);
     }
 }