Skip to content

Commit f7a616c

Browse files
authored
Merge pull request #5800 from rtfd/improve-search-admin
A few small improvements to help with search admin stuff
2 parents 5e25abe + dd12195 commit f7a616c

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

readthedocs/projects/admin.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -312,8 +312,8 @@ class ImportedFileAdmin(admin.ModelAdmin):
312312
"""Admin view for :py:class:`ImportedFile`."""
313313

314314
raw_id_fields = ('project', 'version')
315-
list_display = ('path', 'name', 'version')
316-
search_fields = ('project', 'path')
315+
list_display = ('path', 'version', 'build')
316+
search_fields = ('project__slug', 'version__slug', 'path', 'build')
317317

318318

319319
class DomainAdmin(admin.ModelAdmin):

readthedocs/sphinx_domains/admin.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,9 @@
66

77
class SphinxDomainAdmin(admin.ModelAdmin):
88
list_filter = ('type',)
9+
list_display = ('docs_url', 'version', 'build')
910
raw_id_fields = ('project', 'version')
10-
search_fields = ('doc_name', 'name')
11+
search_fields = ('doc_name', 'name', 'project__slug', 'version__slug', 'build')
1112
readonly_fields = ('created', 'modified')
1213

1314

0 commit comments

Comments
 (0)