Skip to content

Commit 53a5507

Browse files
committed
add usecase to django admin
1 parent 40f9a40 commit 53a5507

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

api/admin.py

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
from django.contrib import admin
22

3-
from api.models import Dataset, Organization
3+
from api.models import Dataset, Organization, UseCase
44

55

66
# Register models needed for authorization app's autocomplete fields
@@ -16,3 +16,10 @@ class DatasetAdmin(admin.ModelAdmin):
1616
list_display = ("title", "organization", "created")
1717
list_filter = ("organization",)
1818
search_fields = ("title", "description")
19+
20+
21+
@admin.register(UseCase)
22+
class UseCaseAdmin(admin.ModelAdmin):
23+
list_display = ("title", "slug", "created")
24+
search_fields = ("title", "slug")
25+
search_fields = ("title", "summary")

0 commit comments

Comments
 (0)