mirror of
https://github.com/OpenSignLabs/OpenSign.git
synced 2026-08-20 14:42:37 +02:00
fix: already placed signature for signers signature embed issue in pdf
This commit is contained in:
@@ -957,18 +957,25 @@ export const multiSignEmbed = async (
|
||||
containerWH
|
||||
) => {
|
||||
for (let item of pngUrl) {
|
||||
let updateItem = item.pos;
|
||||
if (signyourself) {
|
||||
updateItem = item;
|
||||
const typeExist = item.pos.some((data) => data?.type);
|
||||
let updateItem;
|
||||
if (typeExist) {
|
||||
if (signyourself) {
|
||||
updateItem = item.pos;
|
||||
} else {
|
||||
updateItem = item.pos.filter(
|
||||
(data) => data?.options?.status === "required"
|
||||
);
|
||||
}
|
||||
} else {
|
||||
updateItem = item.pos.filter(
|
||||
(data) => data?.options?.status === "required"
|
||||
);
|
||||
updateItem = item.pos;
|
||||
}
|
||||
|
||||
const newWidth = containerWH.width;
|
||||
const scale = isMobile ? pdfOriginalWidth / newWidth : 1;
|
||||
const pageNo = item.pageNumber;
|
||||
const imgUrlList = signyourself ? updateItem.pos : updateItem;
|
||||
const imgUrlList = updateItem;
|
||||
console.log("imgUrllist", imgUrlList);
|
||||
const pages = pdfDoc.getPages();
|
||||
const form = pdfDoc.getForm();
|
||||
const page = pages[pageNo - 1];
|
||||
|
||||
Reference in New Issue
Block a user