This commit is contained in:
David Kennedy 2023-12-04 16:52:41 -05:00
parent 15489a71e2
commit 4344810107
No known key found for this signature in database
GPG key ID: 6528A5386E66B96B
2 changed files with 61 additions and 43 deletions

View file

@ -117,6 +117,11 @@ class ListHeaderAdmin(AuditedAdmin):
)
return filters
# customize the help_text for all formfields for manytomany
def formfield_for_manytomany(self, db_field, request, **kwargs):
formfield = super().formfield_for_manytomany(db_field, request, **kwargs)
formfield.help_text = formfield.help_text + " If more than one value is selected, the change/delete/view actions will be disabled."
return formfield
class UserContactInline(admin.StackedInline):
"""Edit a user's profile on the user page."""