Skip to content

Commit

Permalink
Admin: filtering certificates by course and program (#2215)
Browse files Browse the repository at this point in the history
  • Loading branch information
annagav authored May 20, 2024
1 parent 38dd3af commit 5c54dfe
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions courses/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -436,14 +436,14 @@ class CourseRunCertificateAdmin(TimestampedModelAdmin):
"user",
"course_run",
"get_revoked_state",
"certificate_page_revision",
]
search_fields = [
"course_run__courseware_id",
"course_run__title",
"user__username",
"user__email",
]
list_filter = ["is_revoked", "course_run__course"]
raw_id_fields = ("user",)

def get_revoked_state(self, obj):
Expand All @@ -469,14 +469,14 @@ class ProgramCertificateAdmin(TimestampedModelAdmin):
"user",
"program",
"get_revoked_state",
"certificate_page_revision",
]
search_fields = [
"program__readable_id",
"program__title",
"user__username",
"user__email",
]
list_filter = ["program__title", "is_revoked"]
raw_id_fields = ("user",)

def get_revoked_state(self, obj):
Expand Down

0 comments on commit 5c54dfe

Please sign in to comment.