Skip to content

Commit

Permalink
πŸ§‘β€πŸ’»(admin) add filter and search function to admin mailboxes view
Browse files Browse the repository at this point in the history
add fields to easily filter and search mailboxes on their statuses,
local part and domains
  • Loading branch information
mjeammet committed Jan 7, 2025
1 parent 42d7d00 commit 94a4435
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/backend/mailbox_manager/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,9 @@ class MailDomainAdmin(admin.ModelAdmin):
class MailboxAdmin(admin.ModelAdmin):
"""Admin for mailbox model."""

list_display = ("__str__", "first_name", "last_name", "status")
list_display = ("__str__", "domain", "status")
list_filter = ("status",)
search_fields = ("local_part", "domain__name")


@admin.register(models.MailDomainAccess)
Expand Down

0 comments on commit 94a4435

Please sign in to comment.