🗃️(mailbox_manager) add organization to domain

To be able to provide a SIRET in the ProConnect IdP process
we need to be able to link a mail domain to its organization.
For now this is not mandatory, as we can't detect the organization
and need a frontend process to clarify it.
This commit is contained in:
Quentin BEY
2025-02-10 12:11:31 +01:00
committed by BEY Quentin
parent a386c61729
commit 8faa049046
5 changed files with 103 additions and 2 deletions

View File

@@ -144,12 +144,13 @@ class MailDomainAdmin(admin.ModelAdmin):
list_display = (
"name",
"organization",
"created_at",
"updated_at",
"slug",
"status",
)
search_fields = ("name",)
search_fields = ("name", "organization__name")
readonly_fields = ["created_at", "slug"]
list_filter = ("status",)
inlines = (UserMailDomainAccessInline,)
@@ -158,6 +159,7 @@ class MailDomainAdmin(admin.ModelAdmin):
fetch_domain_status_from_dimail,
fetch_domain_expected_config_from_dimail,
)
autocomplete_fields = ["organization"]
@admin.register(models.Mailbox)