Skip to content

Commit 07933b5

Browse files
Fix: issue of 'something went wrong' err in guest login flow when using quick send
1 parent f6ba4db commit 07933b5

File tree

3 files changed

+13
-9
lines changed

3 files changed

+13
-9
lines changed

apps/OpenSign/src/primitives/GetReportDisplay.js

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -308,14 +308,18 @@ const ReportTable = (props) => {
308308
const sendMail = item?.SendMail || false;
309309
const getUrl = (x) => {
310310
//encode this url value `${item.objectId}/${x.Email}/${x.objectId}` to base64 using `btoa` function
311-
const encodeBase64 = btoa(
312-
`${item.objectId}/${x.Email}/${x.objectId}/${sendMail}`
313-
);
314-
return `${host}/login/${encodeBase64}`;
311+
if (x.objectId) {
312+
const encodeBase64 = btoa(
313+
`${item.objectId}/${x.signerPtr.Email}/${x.signerPtr.objectId}/${sendMail}`
314+
);
315+
return `${host}/login/${encodeBase64}`;
316+
} else {
317+
const encodeBase64 = btoa(`${item.objectId}/${x.email}`);
318+
return `${host}/login/${encodeBase64}`;
319+
}
315320
};
316-
317-
const urls = item.Signers.map((x) => ({
318-
email: x.Email,
321+
const urls = item?.Placeholders?.map((x) => ({
322+
email: x.email ? x.email : x.signerPtr.Email,
319323
url: getUrl(x)
320324
}));
321325
setShareUrls(urls);

apps/OpenSignServer/cloud/parsefunction/createBatchDocs.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -166,8 +166,6 @@ export default async function createBatchDocs(request) {
166166
createdAt: response.data[i]?.success?.createdAt,
167167
}));
168168
for (let i = 0; i < updateDocuments.length; i++) {
169-
console.log('updateDocuments ', updateDocuments);
170-
171169
sendMail(updateDocuments[i], sessionToken);
172170
}
173171
return 'success';

apps/OpenSignServer/cloud/parsefunction/reportsJson.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,7 @@ export default function reportJson(id, userId) {
102102
'AuditTrail.UserPtr',
103103
'ExpiryDate',
104104
'SendMail',
105+
'Placeholders',
105106
],
106107
};
107108
// completed documents report
@@ -220,6 +221,7 @@ export default function reportJson(id, userId) {
220221
'AuditTrail',
221222
'AuditTrail.UserPtr',
222223
'ExpiryDate',
224+
'Placeholders',
223225
],
224226
};
225227
// Recent signature requests report show on dashboard

0 commit comments

Comments
 (0)