WebViewer Version: 11.7.1
Do you have an issue with a specific file(s)? NO
Can you reproduce using one of our samples or online demos? NO
Are you using the WebViewer server? NO
Does the issue only happen on certain browsers? NO
Is your issue related to a front-end framework? NO
Is your issue related to annotations? Yes
Please give a brief summary of your issue:
When a user adds the same stamp multiple times across all pages (bulk stamping), the stamp is visually added to all pages in the viewer. However, intermittently one page (most often page 2) does not receive the correct XFDF data.
Please describe your issue and provide steps to reproduce it:
Load a multi-page PDF document (10+ pages increases repro chance)
- Add a stamp on the current page
- Choose âApply stamp to all pagesâ
- Repeat the same action multiple times using the same stamp
- Reload the document or fetch annotations from backend
Expected Result
-
The stamp should be added to every page
-
Each page should generate correct XFDF
-
No pages should be skipped
Actual Result
-
One page (most commonly page 2) is missing the stamp
-
XFDF for that page is not generated or is incorrect
-
Viewer UI may temporarily show the stamp, but it is not persisted
if (selectedOption === 'all') {
saveStamp = false;
$('.common-loading-spinner-text').text('Please do not close your browser or press the back button until the stamps has been fully added to the document.');
$('.common-loading').show();
let bulkRequest = [];
isBulkStamping = true;
let lastPageNumber = 0;
try {
for (let pageNumber = 1; pageNumber <= totalPages; pageNumber++) {
lastPageNumber = pageNumber;
let annot;
if (pageNumber === currentPage) {
annot = lastStamp;
} else {
annot = annotationManager.getAnnotationCopy(lastStamp);
annot.PageNumber = pageNumber;
annotationManager.addAnnotation(annot);
}
const annotData = await annotationManager.exportAnnotationCommand();
bulkRequest.push({
caseId: $('#Id').val(),
contentItemId: $('#ContentItemId').text().trim(),
annotData,
annotType: 'Stamp',
annotId: annot.Id,
pageNumber: pageNumber - 1,
currentUserId: userID,
status: 'None',
});
if (bulkRequest.length === 15 || lastPageNumber === totalPages) {
PartialApryse.ApplyBulkStamp([...bulkRequest]);
bulkRequest = [];
}
}
documentViewer.refreshAll();
isBulkStamping = false;
await annotationManager.exportAnnotationCommand();
} catch (err) {
console.error('Bulk stamping failed:', err);
$('.common-loading').hide();
} finally {
$('.common-loading').hide();
}
}
Please provide a link to a minimal sample where the issue is reproducible: