Skip to content

Added certificate download and verification #487

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

Merged
merged 3 commits into from
May 7, 2024

Conversation

dhruvilmehta
Copy link
Contributor

@dhruvilmehta dhruvilmehta commented Apr 24, 2024

PR Fixes:

Features added:

  1. Download PDF/PNG
  2. Certificate verification page
  3. Share on Twitter (LinkedIn URl not working)

Resolves #483

Checklist before requesting a review

  • I have performed a self-review of my code
  • I assure there is no similar/duplicate pull request regarding same issue

Current Certificate design (we can change the template, everything is middle aligned.):
image

@dhruvilmehta dhruvilmehta marked this pull request as draft April 24, 2024 00:35
@dhruvilmehta
Copy link
Contributor Author

This is what the certificate verification page looks like.

Screenshot 2024-04-26 005855

Certificates page:
image

I am not storing any certificates since fetching certificates will not be a frequent task. Instead, I am generating a certificate image every time it is requested.
If you wish to store all certificates then we need to modify some code to store the certificates on the server.

We can also download PNG files to share on LinkedIn/Twitter.
Otherwise, certificates are available on /certificates/verify/{certificateId} , which we are sharing on Twitter/LinkedIn since we cannot directly share png files.

@dhruvilmehta dhruvilmehta marked this pull request as ready for review April 26, 2024 08:18
@dhruvilmehta dhruvilmehta changed the title Added pdf download certificate feature Added certificate download and verification Apr 27, 2024

const CertificatePage = async () => {
const session = await getServerSession(authOptions);
const purchases = await db.userPurchases.findMany({
Copy link
Contributor

Choose a reason for hiding this comment

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

This needs to change unfortunately since not all purchases are in this db
Some are fetched from appx
Let me take care of this

@hkirat hkirat merged commit c1168ae into code100x:main May 7, 2024
1 check passed
@hkirat
Copy link
Contributor

hkirat commented May 7, 2024

/bounty $100

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

feature: Certificate for users in 0-1
2 participants