From 5b84a16e467c5988305cecba16ab78126a1274c8 Mon Sep 17 00:00:00 2001 From: Braden MacDonald Date: Wed, 6 May 2026 18:25:36 -0700 Subject: [PATCH] fix: django admin wasn't showing details of content libraries (#38578) FieldError at /admin/content_libraries/contentlibrary/:id/change/ Unknown field(s) (authorized_lti_configs) --- openedx/core/djangoapps/content_libraries/admin.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/openedx/core/djangoapps/content_libraries/admin.py b/openedx/core/djangoapps/content_libraries/admin.py index 42947250c5e8..f0ab84b91526 100644 --- a/openedx/core/djangoapps/content_libraries/admin.py +++ b/openedx/core/djangoapps/content_libraries/admin.py @@ -16,9 +16,9 @@ class ContentLibraryAdmin(admin.ModelAdmin): "library_key", "org", "slug", + "learning_package", "allow_public_learning", "allow_public_read", - "authorized_lti_configs", ) list_display = ("slug", "org",) @@ -26,7 +26,7 @@ def get_readonly_fields(self, request, obj=None): """ Ensure that 'slug' and 'uuid' cannot be edited after creation. """ + always_ro_fields = ["library_key", "learning_package"] if obj: - return ["library_key", "org", "slug"] - else: - return ["library_key", ] + return [*always_ro_fields, "org", "slug"] + return always_ro_fields