Skip to content

Commit

Permalink
Merge pull request #1111 from CodingPirates/1110-bugopret-ny-afdeling…
Browse files Browse the repository at this point in the history
…-kan-ikke-vælge-forening

Admin > Department: Autocomplete field for Union field
  • Loading branch information
rasmusselsmark authored Oct 7, 2024
2 parents d80ced7 + 197d1a0 commit 3665d2a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions members/admin/department_admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ class DepartmentAdmin(admin.ModelAdmin):
"closed_dtm",
"has_waiting_list",
)
autocomplete_fields = ("union",)
raw_id_fields = ("union",)
search_fields = (
"name",
Expand Down
1 change: 1 addition & 0 deletions members/admin/union_admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,7 @@ class UnionAdmin(admin.ModelAdmin):
"founded_at",
"closed_at",
)
search_fields = ("name",)
filter_horizontal = ["board_members"]
raw_id_fields = ("chairman", "second_chair", "cashier", "secretary")

Expand Down

0 comments on commit 3665d2a

Please sign in to comment.