diff --git a/django/contrib/admin/widgets.py b/django/contrib/admin/widgets.py index 74004a7ba7..67742470bf 100644 --- a/django/contrib/admin/widgets.py +++ b/django/contrib/admin/widgets.py @@ -27,6 +27,8 @@ class FilteredSelectMultiple(forms.SelectMultiple): catalog has been loaded in the page """ + use_fieldset = True + class Media: js = [ "admin/js/core.js", @@ -50,6 +52,8 @@ class FilteredSelectMultiple(forms.SelectMultiple): class BaseAdminDateWidget(forms.DateInput): + use_fieldset = True + class Media: js = [ "admin/js/calendar.js", @@ -66,6 +70,8 @@ class AdminDateWidget(BaseAdminDateWidget): class BaseAdminTimeWidget(forms.TimeInput): + use_fieldset = True + class Media: js = [ "admin/js/calendar.js", @@ -86,6 +92,7 @@ class AdminSplitDateTime(forms.SplitDateTimeWidget): A SplitDateTime Widget that has some admin-specific styling. """ + use_fieldset = True template_name = "admin/widgets/split_datetime.html" def __init__(self, attrs=None): @@ -102,10 +109,12 @@ class AdminSplitDateTime(forms.SplitDateTimeWidget): class AdminRadioSelect(forms.RadioSelect): + use_fieldset = True template_name = "admin/widgets/radio.html" class AdminFileWidget(forms.ClearableFileInput): + use_fieldset = True template_name = "admin/widgets/clearable_file_input.html" @@ -135,6 +144,7 @@ class ForeignKeyRawIdWidget(forms.TextInput): in a