From adbf1cd95f659012fdca953f940630514871381e Mon Sep 17 00:00:00 2001 From: Patrizio Bekerle <patrizio@bekerle.com> Date: Thu, 1 Apr 2021 10:16:39 +0200 Subject: [PATCH] Implement annotating of PDFs for qualified signature pdf upload (#37) --- src/dbp-qualified-signature-pdf-upload.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/dbp-qualified-signature-pdf-upload.js b/src/dbp-qualified-signature-pdf-upload.js index cc7e354..b78d1f4 100644 --- a/src/dbp-qualified-signature-pdf-upload.js +++ b/src/dbp-qualified-signature-pdf-upload.js @@ -54,6 +54,7 @@ class QualifiedSignaturePdfUpload extends ScopedElementsMixin(DBPSignatureLitEle this.allowAnnotating = false; this.queuedFilesAnnotations = []; this.queuedFilesAnnotationsCount = 0; + this.queuedFilesEnabledAnnotations = []; this.isAnnotationViewVisible = false; this.activity = new Activity(metadata); @@ -195,7 +196,9 @@ class QualifiedSignaturePdfUpload extends ScopedElementsMixin(DBPSignatureLitEle fileSize: humanFileSize(file.size, false), }); - await this.uploadFile(file, params); + const annotationsEnabled = this.isAnnotationsEnabledForKey(key); + const annotations = this.takeAnnotationsFromQueue(key); + await this.uploadFile(file, params, annotationsEnabled ? annotations : []); this.uploadInProgress = false; } -- GitLab