Skip to content

feat: display corporate catalog name on generated certificates#84

Open
bra-i-am wants to merge 3 commits into
nau/teak.masterfrom
bc/add-corporate-info
Open

feat: display corporate catalog name on generated certificates#84
bra-i-am wants to merge 3 commits into
nau/teak.masterfrom
bc/add-corporate-info

Conversation

@bra-i-am

@bra-i-am bra-i-am commented Feb 27, 2026

Copy link
Copy Markdown

This PR updates the certificate template to display the corporate catalog name associated with the completed course.

It retrieves the learner’s verified enrollment and related catalog information, and conditionally renders the corporate catalog name on the generated certificate when available.

Caution

The catalog information is only added if the user has a seat assigned in a catalog for the course

Screenshot

image

has_verified_enrollment = CourseEnrollment.objects.filter(
user=user,
course_id=course_key,
mode="verified",

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

My only comment here is: certificates are delivered in verified and honor mode. It worth to validate this assumption.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

@dcoa, thanks for your feedback

You are right, in fact, according to the logic, it takes all the paid enrollments as valid ones

@bra-i-am bra-i-am requested a review from dcoa March 18, 2026 20:29
course_key = CourseKey.from_string(course_id)

# Ensure user has a PAID enrollment (not audit/honor)
OPEN_ENROLLMENT_MODES = frozenset({"audit", "honor"})

@dcoa dcoa Mar 19, 2026

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

it should be honor, verified, isn't it? audit is not paid

@igobranco

Copy link
Copy Markdown
Member

@dcoa and @bra-i-am on NAU we haven't been using that certificate template. We are using the DB loaded template. Nevertheless we still need to know how to show that information on those templates.
On the long run, we should copy paste that template, assets, etc. to this repository. But that hasn't been a priority.

Entering to specific code.
The has_paid_enrollment if shouldn't exist on the certificates. There isn't any business requirement for that if. The only relevant requirement is to show an additional information about the catalog and that isn't related to the course mode.

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.

3 participants