Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix: Signature not showing #8235

Open
wants to merge 7 commits into
base: develop
Choose a base branch
from
Open

Fix: Signature not showing #8235

wants to merge 7 commits into from

Conversation

jamil314
Copy link
Collaborator

No description provided.

Copy link

Oops! Looks like you forgot to update the changelog. When updating CHANGELOG.md, please consider the following:

  • Changelog is read by country implementors who might not always be familiar with all technical details of OpenCRVS. Keep language high-level, user friendly and avoid technical references to internals.
  • Answer "What's new?", "Why was the change made?" and "Why should I care?" for each change.
  • If it's a breaking change, include a migration guide answering "What do I need to do to upgrade?".

@jamil314 jamil314 added 💅 Waiting For Review 🚀 Ready to deploy Deployment automation should pick this PR up and start auto-deploying it labels Dec 19, 2024
@ocrvs-bot
Copy link
Collaborator

Your environment is deployed to https://ocrvs-6213.opencrvs.dev

@jamil314 jamil314 requested a review from Zangetsu101 December 23, 2024 06:16
Comment on lines 211 to 236
const resolvedSignatures = await Promise.all(
SIGNATURE_KEYS.map((k) => ({
signatureKey: k,
url: templateValues[k]
}))
.filter(({ url }) => Boolean(url))
.map(({ signatureKey, url }) => {
return fetchImageAsBase64(url as string).then((value) => ({
[signatureKey]: value
}))
})
).then((res) => res.reduce((acc, cur) => ({ ...acc, ...cur }), {}))
templateValues = {
...templateValues,
...resolvedSignatures
}

if (templateValues.registrar) {
fetchImageAsBase64(
(templateValues.registrar as any).signature as string
).then((value) => {
;(templateValues.registrar as any).signature = value
})
}
return executeHandlebarsTemplate(svgTemplate, templateValues, state)
}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's make this dynamic

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🚀 Ready to deploy Deployment automation should pick this PR up and start auto-deploying it 💅 Waiting For Review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants