diff --git a/EnvelopeGenerator.CommonServices/Jobs/FinalizeDocument/PDFBurner.vb b/EnvelopeGenerator.CommonServices/Jobs/FinalizeDocument/PDFBurner.vb index a969da8b..347bb888 100644 --- a/EnvelopeGenerator.CommonServices/Jobs/FinalizeDocument/PDFBurner.vb +++ b/EnvelopeGenerator.CommonServices/Jobs/FinalizeDocument/PDFBurner.vb @@ -20,9 +20,6 @@ Namespace Jobs.FinalizeDocument Private ReadOnly Manager As AnnotationManager Private ReadOnly LicenseManager As LicenseManager - Private Const ANNOTATION_TYPE_IMAGE = "pspdfkit/image" - Private Const ANNOTATION_TYPE_INK = "pspdfkit/ink" - Private Const ANNOTATION_TYPE_WIDGET = "pspdfkit/widget" Private Property _pdfBurnerParams As PDFBurnerParams Public Sub New(pLogConfig As LogConfig, pGDPictureLicenseKey As String, pdfBurnerParams As PDFBurnerParams) @@ -106,16 +103,13 @@ Namespace Jobs.FinalizeDocument Logger.Debug("Adding AnnotationID: " + oAnnotation.id) Select Case oAnnotation.type - Case ANNOTATION_TYPE_IMAGE - + Case AnnotationType.Image AddImageAnnotation(oAnnotation, oAnnotationData.attachments) Exit Select - - Case ANNOTATION_TYPE_INK + Case AnnotationType.Ink AddInkAnnotation(oAnnotation) Exit Select - - Case ANNOTATION_TYPE_WIDGET + Case AnnotationType.Widget 'Add form field values Dim formFieldValue = oAnnotationData.formFieldValues.FirstOrDefault(Function(fv) fv.name = oAnnotation.id) If formFieldValue IsNot Nothing AndAlso Not _pdfBurnerParams.IgnoredLabels.Contains(formFieldValue.value) Then @@ -196,6 +190,12 @@ Namespace Jobs.FinalizeDocument #End Region #Region "Model" + Friend Class AnnotationType + Public Const Image As String = "pspdfkit/image" + Public Const Ink As String = "pspdfkit/ink" + Public Const Widget As String = "pspdfkit/widget" + End Class + Friend Class AnnotationData Public Property annotations As List(Of Annotation)