From 33bf15613793814a6d8af95efb01c92d17923930 Mon Sep 17 00:00:00 2001
From: Artsiom Tsybulko <tsybulko.artem@gmail.com>
Date: Wed, 23 Jul 2025 13:08:43 +0300
Subject: [PATCH 1/2] 41669 - fix fieldType type

---
 .../Model/EncryptedRCLItem.cs                   |  2 +-
 .../Model/EncryptedRCLResult.cs                 |  2 +-
 .../Model/Ext/ImagesExtensions.cs               |  4 ++--
 .../Model/ImagesField.cs                        | 17 +++++++++--------
 .../Model/LicenseItem.cs                        |  2 +-
 .../Model/LicenseResult.cs                      |  2 +-
 6 files changed, 15 insertions(+), 14 deletions(-)

diff --git a/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLItem.cs b/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLItem.cs
index b7ffe8c..9857dbf 100644
--- a/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLItem.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLItem.cs
@@ -56,7 +56,7 @@ protected EncryptedRCLItem() { }
         /// </summary>
         /// <value>Base64 encoded data</value>
         /*
-        <example>[B@638eef98</example>
+        <example>[B@3e7785cf</example>
         */
         [DataMember(Name = "EncryptedRCL", IsRequired = true, EmitDefaultValue = true)]
         public byte[] EncryptedRCL { get; set; }
diff --git a/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLResult.cs b/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLResult.cs
index 8fb9032..a4e3763 100644
--- a/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLResult.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLResult.cs
@@ -62,7 +62,7 @@ protected EncryptedRCLResult() { }
         /// </summary>
         /// <value>Base64 encoded data</value>
         /*
-        <example>[B@638eef98</example>
+        <example>[B@3e7785cf</example>
         */
         [DataMember(Name = "EncryptedRCL", IsRequired = true, EmitDefaultValue = true)]
         public byte[] EncryptedRCL { get; set; }
diff --git a/src/Regula.DocumentReader.WebClient/Model/Ext/ImagesExtensions.cs b/src/Regula.DocumentReader.WebClient/Model/Ext/ImagesExtensions.cs
index d5de775..719326a 100644
--- a/src/Regula.DocumentReader.WebClient/Model/Ext/ImagesExtensions.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/Ext/ImagesExtensions.cs
@@ -8,7 +8,7 @@ public static ImagesField GetField(this Images imgs, GraphicFieldType fieldType)
         {
             foreach (var field in imgs.FieldList) 
             {
-                if (field.FieldType == fieldType) return field;
+                if (field.FieldType == (int)fieldType) return field;
             }
             
             return null;
@@ -20,7 +20,7 @@ public static List<ImagesField> GetFields(this Images imgs, GraphicFieldType fie
             
             foreach (var field in imgs.FieldList) 
             {
-                if (field.FieldType == fieldType)
+                if (field.FieldType == (int)fieldType)
                     fields.Add(field);
             }
             
diff --git a/src/Regula.DocumentReader.WebClient/Model/ImagesField.cs b/src/Regula.DocumentReader.WebClient/Model/ImagesField.cs
index 1b307f5..9c9126e 100644
--- a/src/Regula.DocumentReader.WebClient/Model/ImagesField.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/ImagesField.cs
@@ -32,12 +32,6 @@ namespace Regula.DocumentReader.WebClient.Model
     [DataContract(Name = "ImagesField")]
     public partial class ImagesField : IValidatableObject
     {
-
-        /// <summary>
-        /// Gets or Sets FieldType
-        /// </summary>
-        [DataMember(Name = "fieldType", IsRequired = true, EmitDefaultValue = true)]
-        public GraphicFieldType FieldType { get; set; }
         /// <summary>
         /// Initializes a new instance of the <see cref="ImagesField" /> class.
         /// </summary>
@@ -47,10 +41,10 @@ protected ImagesField() { }
         /// Initializes a new instance of the <see cref="ImagesField" /> class.
         /// </summary>
         /// <param name="fieldName">Human readable field name. Do not bind to this name - use GraphicFieldType instead. (required).</param>
-        /// <param name="fieldType">fieldType (required).</param>
+        /// <param name="fieldType">The value can be from GraphicFieldType or TextFieldType enum. (required).</param>
         /// <param name="valueList">valueList (required).</param>
         /// <param name="valueCount">Field value count.</param>
-        public ImagesField(string fieldName = default(string), GraphicFieldType fieldType = default(GraphicFieldType), List<ImagesFieldValue> valueList = default(List<ImagesFieldValue>), decimal valueCount = default(decimal))
+        public ImagesField(string fieldName = default(string), int fieldType = default(int), List<ImagesFieldValue> valueList = default(List<ImagesFieldValue>), decimal valueCount = default(decimal))
         {
             // to ensure "fieldName" is required (not null)
             if (fieldName == null)
@@ -75,6 +69,13 @@ protected ImagesField() { }
         [DataMember(Name = "fieldName", IsRequired = true, EmitDefaultValue = true)]
         public string FieldName { get; set; }
 
+        /// <summary>
+        /// The value can be from GraphicFieldType or TextFieldType enum.
+        /// </summary>
+        /// <value>The value can be from GraphicFieldType or TextFieldType enum.</value>
+        [DataMember(Name = "fieldType", IsRequired = true, EmitDefaultValue = true)]
+        public int FieldType { get; set; }
+
         /// <summary>
         /// Gets or Sets ValueList
         /// </summary>
diff --git a/src/Regula.DocumentReader.WebClient/Model/LicenseItem.cs b/src/Regula.DocumentReader.WebClient/Model/LicenseItem.cs
index 3a3c30f..99bc7a4 100644
--- a/src/Regula.DocumentReader.WebClient/Model/LicenseItem.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/LicenseItem.cs
@@ -56,7 +56,7 @@ protected LicenseItem() { }
         /// </summary>
         /// <value>Base64 encoded data</value>
         /*
-        <example>[B@19a26868</example>
+        <example>[B@62d85d39</example>
         */
         [DataMember(Name = "License", IsRequired = true, EmitDefaultValue = true)]
         public byte[] License { get; set; }
diff --git a/src/Regula.DocumentReader.WebClient/Model/LicenseResult.cs b/src/Regula.DocumentReader.WebClient/Model/LicenseResult.cs
index b4fdf2f..4ca302b 100644
--- a/src/Regula.DocumentReader.WebClient/Model/LicenseResult.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/LicenseResult.cs
@@ -62,7 +62,7 @@ protected LicenseResult() { }
         /// </summary>
         /// <value>Base64 encoded data</value>
         /*
-        <example>[B@19a26868</example>
+        <example>[B@62d85d39</example>
         */
         [DataMember(Name = "License", IsRequired = true, EmitDefaultValue = true)]
         public byte[] License { get; set; }

From 33a349f2e51236979b378f991f9402db47eed9b6 Mon Sep 17 00:00:00 2001
From: Artsiom Tsybulko <tsybulko.artem@gmail.com>
Date: Thu, 24 Jul 2025 09:49:45 +0300
Subject: [PATCH 2/2] 41669 - rollback fieldType type

---
 .../Model/EncryptedRCLItem.cs                   |  2 +-
 .../Model/EncryptedRCLResult.cs                 |  2 +-
 .../Model/Ext/ImagesExtensions.cs               |  4 ++--
 .../Model/ImagesField.cs                        | 17 ++++++++---------
 .../Model/LicenseItem.cs                        |  2 +-
 .../Model/LicenseResult.cs                      |  2 +-
 6 files changed, 14 insertions(+), 15 deletions(-)

diff --git a/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLItem.cs b/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLItem.cs
index 9857dbf..b7ffe8c 100644
--- a/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLItem.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLItem.cs
@@ -56,7 +56,7 @@ protected EncryptedRCLItem() { }
         /// </summary>
         /// <value>Base64 encoded data</value>
         /*
-        <example>[B@3e7785cf</example>
+        <example>[B@638eef98</example>
         */
         [DataMember(Name = "EncryptedRCL", IsRequired = true, EmitDefaultValue = true)]
         public byte[] EncryptedRCL { get; set; }
diff --git a/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLResult.cs b/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLResult.cs
index a4e3763..8fb9032 100644
--- a/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLResult.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/EncryptedRCLResult.cs
@@ -62,7 +62,7 @@ protected EncryptedRCLResult() { }
         /// </summary>
         /// <value>Base64 encoded data</value>
         /*
-        <example>[B@3e7785cf</example>
+        <example>[B@638eef98</example>
         */
         [DataMember(Name = "EncryptedRCL", IsRequired = true, EmitDefaultValue = true)]
         public byte[] EncryptedRCL { get; set; }
diff --git a/src/Regula.DocumentReader.WebClient/Model/Ext/ImagesExtensions.cs b/src/Regula.DocumentReader.WebClient/Model/Ext/ImagesExtensions.cs
index 719326a..d5de775 100644
--- a/src/Regula.DocumentReader.WebClient/Model/Ext/ImagesExtensions.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/Ext/ImagesExtensions.cs
@@ -8,7 +8,7 @@ public static ImagesField GetField(this Images imgs, GraphicFieldType fieldType)
         {
             foreach (var field in imgs.FieldList) 
             {
-                if (field.FieldType == (int)fieldType) return field;
+                if (field.FieldType == fieldType) return field;
             }
             
             return null;
@@ -20,7 +20,7 @@ public static List<ImagesField> GetFields(this Images imgs, GraphicFieldType fie
             
             foreach (var field in imgs.FieldList) 
             {
-                if (field.FieldType == (int)fieldType)
+                if (field.FieldType == fieldType)
                     fields.Add(field);
             }
             
diff --git a/src/Regula.DocumentReader.WebClient/Model/ImagesField.cs b/src/Regula.DocumentReader.WebClient/Model/ImagesField.cs
index 9c9126e..1b307f5 100644
--- a/src/Regula.DocumentReader.WebClient/Model/ImagesField.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/ImagesField.cs
@@ -32,6 +32,12 @@ namespace Regula.DocumentReader.WebClient.Model
     [DataContract(Name = "ImagesField")]
     public partial class ImagesField : IValidatableObject
     {
+
+        /// <summary>
+        /// Gets or Sets FieldType
+        /// </summary>
+        [DataMember(Name = "fieldType", IsRequired = true, EmitDefaultValue = true)]
+        public GraphicFieldType FieldType { get; set; }
         /// <summary>
         /// Initializes a new instance of the <see cref="ImagesField" /> class.
         /// </summary>
@@ -41,10 +47,10 @@ protected ImagesField() { }
         /// Initializes a new instance of the <see cref="ImagesField" /> class.
         /// </summary>
         /// <param name="fieldName">Human readable field name. Do not bind to this name - use GraphicFieldType instead. (required).</param>
-        /// <param name="fieldType">The value can be from GraphicFieldType or TextFieldType enum. (required).</param>
+        /// <param name="fieldType">fieldType (required).</param>
         /// <param name="valueList">valueList (required).</param>
         /// <param name="valueCount">Field value count.</param>
-        public ImagesField(string fieldName = default(string), int fieldType = default(int), List<ImagesFieldValue> valueList = default(List<ImagesFieldValue>), decimal valueCount = default(decimal))
+        public ImagesField(string fieldName = default(string), GraphicFieldType fieldType = default(GraphicFieldType), List<ImagesFieldValue> valueList = default(List<ImagesFieldValue>), decimal valueCount = default(decimal))
         {
             // to ensure "fieldName" is required (not null)
             if (fieldName == null)
@@ -69,13 +75,6 @@ protected ImagesField() { }
         [DataMember(Name = "fieldName", IsRequired = true, EmitDefaultValue = true)]
         public string FieldName { get; set; }
 
-        /// <summary>
-        /// The value can be from GraphicFieldType or TextFieldType enum.
-        /// </summary>
-        /// <value>The value can be from GraphicFieldType or TextFieldType enum.</value>
-        [DataMember(Name = "fieldType", IsRequired = true, EmitDefaultValue = true)]
-        public int FieldType { get; set; }
-
         /// <summary>
         /// Gets or Sets ValueList
         /// </summary>
diff --git a/src/Regula.DocumentReader.WebClient/Model/LicenseItem.cs b/src/Regula.DocumentReader.WebClient/Model/LicenseItem.cs
index 99bc7a4..3a3c30f 100644
--- a/src/Regula.DocumentReader.WebClient/Model/LicenseItem.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/LicenseItem.cs
@@ -56,7 +56,7 @@ protected LicenseItem() { }
         /// </summary>
         /// <value>Base64 encoded data</value>
         /*
-        <example>[B@62d85d39</example>
+        <example>[B@19a26868</example>
         */
         [DataMember(Name = "License", IsRequired = true, EmitDefaultValue = true)]
         public byte[] License { get; set; }
diff --git a/src/Regula.DocumentReader.WebClient/Model/LicenseResult.cs b/src/Regula.DocumentReader.WebClient/Model/LicenseResult.cs
index 4ca302b..b4fdf2f 100644
--- a/src/Regula.DocumentReader.WebClient/Model/LicenseResult.cs
+++ b/src/Regula.DocumentReader.WebClient/Model/LicenseResult.cs
@@ -62,7 +62,7 @@ protected LicenseResult() { }
         /// </summary>
         /// <value>Base64 encoded data</value>
         /*
-        <example>[B@62d85d39</example>
+        <example>[B@19a26868</example>
         */
         [DataMember(Name = "License", IsRequired = true, EmitDefaultValue = true)]
         public byte[] License { get; set; }
