Skip to content

Bug: Autocomplete does not work when adding a nested inline #237

@beeekey

Description

@beeekey

I have an Inline model as following:

class SomeModelInline(InlinePermissionsMixin, nested_admin.NestedStackedInline):
    model = MyModel
    extra = 1
    autocomplete_fields = ['type']
    form = MyModelForm

When setting extra=1 the autocomplete works for the first entry (works for all which are defined with extra) , when adding another inline entry by clicking the + add button, the autocomplete field is empty. Comparing the html of these two elements, there are a lot of html tags missing.

I am using Django 4.2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions