diff --git a/frappe-ui b/frappe-ui index 2898a0bd..3b700c7a 160000 --- a/frappe-ui +++ b/frappe-ui @@ -1 +1 @@ -Subproject commit 2898a0bdd1a07433e5f6adedb42786177c473d50 +Subproject commit 3b700c7a8a77277e62cdc770ccad6fd79b07a2a5 diff --git a/lms/lms/doctype/lms_certificate/lms_certificate.js b/lms/lms/doctype/lms_certificate/lms_certificate.js index 9a469c6d..eb0d9f86 100644 --- a/lms/lms/doctype/lms_certificate/lms_certificate.js +++ b/lms/lms/doctype/lms_certificate/lms_certificate.js @@ -22,7 +22,9 @@ frappe.ui.form.on("LMS Certificate", { refresh: (frm) => { if (frm.doc.name) frm.add_web_link( - `/lms/courses/${frm.doc.course}/${frm.doc.name}`, + `/api/method/frappe.utils.print_format.download_pdf?doctype=LMS+Certificate&name=${ + frm.doc.name + }&format=${encodeURIComponent(frm.doc.template)}`, "See on Website" ); }, diff --git a/lms/lms/doctype/lms_certificate/lms_certificate.py b/lms/lms/doctype/lms_certificate/lms_certificate.py index f7e1193e..28e8864e 100644 --- a/lms/lms/doctype/lms_certificate/lms_certificate.py +++ b/lms/lms/doctype/lms_certificate/lms_certificate.py @@ -27,6 +27,7 @@ class LMSCertificate(Document): "course_name": self.course, "course_title": frappe.db.get_value("LMS Course", self.course, "title"), "certificate_name": self.name, + "template": self.template, } if custom_template: diff --git a/lms/templates/emails/certification.html b/lms/templates/emails/certification.html index 3d47b1b9..f7d2d8c9 100644 --- a/lms/templates/emails/certification.html +++ b/lms/templates/emails/certification.html @@ -7,10 +7,10 @@


- {{ _("With this certification, you can now showcase your updated skills and share your achievement with your colleagues and on LinkedIn. To access your certificate, please click on the link provided below.") }} + {{ _("With this certification, you can now showcase your updated skills and share your achievement with your colleagues and on LinkedIn. To access your certificate, please click on the link provided below. Make sure you are logged in to the portal.") }}


-{{ _("Certificate Link") }} +{{ _("Certificate Link") }}

{{ _("Once again, congratulations on this significant accomplishment.")}}