add isLabel property

This commit is contained in:
tekh 2025-10-09 17:42:34 +02:00
parent 7b6f916486
commit ce7ca39c39

View File

@ -1,11 +1,12 @@
Imports System.Drawing
Imports System.Collections.Immutable
Imports System.Drawing
Imports System.IO
Imports DevExpress.DataProcessing
Imports DigitalData.Modules.Base
Imports DigitalData.Modules.Logging
Imports EnvelopeGenerator.CommonServices.Jobs.FinalizeDocument.FinalizeDocumentExceptions
Imports GdPicture14
Imports Newtonsoft.Json
Imports EnvelopeGenerator.CommonServices.Jobs.FinalizeDocument.FinalizeDocumentExceptions
Imports DevExpress.DataProcessing
Namespace Jobs.FinalizeDocument
Public Class PDFBurner
@ -68,6 +69,18 @@ Namespace Jobs.FinalizeDocument
End Using
End Function
Public Shared ReadOnly FormFieldIndex As ImmutableDictionary(Of String, Integer) =
New Dictionary(Of String, Integer) From {
{Nothing, 0},
{"signature", 0},
{"date", 1},
{"date_label", 2},
{"city", 3},
{"city_label", 4},
{"position", 5},
{"position_label", 6}
}.ToImmutableDictionary()
Private Sub AddInstantJSONAnnotationToPDF(pInstantJSON As String)
Dim oAnnotationData = JsonConvert.DeserializeObject(Of AnnotationData)(pInstantJSON)
@ -104,6 +117,7 @@ Namespace Jobs.FinalizeDocument
End Select
isSeal = False
Next
End Sub
@ -210,6 +224,17 @@ Namespace Jobs.FinalizeDocument
Public hasStructuredID As Boolean = False
Public ReadOnly Property isLabel As Boolean
Get
If String.IsNullOrEmpty(fieldName) Then
Return False
End If
Dim parts As String() = fieldName.Split("_"c)
Return parts.Length > 1 AndAlso parts(1) = "label"
End Get
End Property
Public Property id As String
Get
Return _id