Skip to content

Commit

Permalink
Make admin collections searchable by config_folder
Browse files Browse the repository at this point in the history
  • Loading branch information
code-geek committed Nov 27, 2023
1 parent 5351b72 commit 7ef4239
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions sde_collections/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,9 @@ def import_candidate_urls_secret_test(modeladmin, request, queryset):

@admin.action(description="Import candidate URLs from Secret Production")
def import_candidate_urls_secret_production(modeladmin, request, queryset):
import_candidate_urls_from_api_caller(modeladmin, request, queryset, "secret_production")
import_candidate_urls_from_api_caller(
modeladmin, request, queryset, "secret_production"
)


class ExportCsvMixin:
Expand Down Expand Up @@ -162,7 +164,7 @@ class CollectionAdmin(admin.ModelAdmin, ExportCsvMixin, UpdateConfigMixin):
)
readonly_fields = ("config_folder",)
list_filter = ("division", "curation_status", "workflow_status", "turned_on")
search_fields = ("name", "url")
search_fields = ("name", "url", "config_folder")
actions = [
"export_as_csv",
"update_config",
Expand Down

0 comments on commit 7ef4239

Please sign in to comment.