class documentation

Select widget mixin that loads options from AutocompleteJsonView via AJAX. Renders the necessary data attributes for select2 and adds the static form media.

Method __init__ Undocumented
Method build_attrs Set select2's AJAX attributes.
Method get_url Undocumented
Method optgroups Return selected options based on the ModelChoiceIterator.
Class Variable url_name Undocumented
Instance Variable admin_site Undocumented
Instance Variable attrs Undocumented
Instance Variable choices Undocumented
Instance Variable db Undocumented
Instance Variable field Undocumented
Instance Variable i18n_name Undocumented
Property media Undocumented
def __init__(self, field, admin_site, attrs=None, choices=(), using=None): (source)

Undocumented

def build_attrs(self, base_attrs, extra_attrs=None): (source)

Set select2's AJAX attributes. Attributes can be set using the html5 data attribute. Nested attributes require a double dash as per https://select2.org/configuration/data-attributes#nested-subkey-options

def get_url(self): (source)

Undocumented

def optgroups(self, name, value, attr=None): (source)

Return selected options based on the ModelChoiceIterator.

url_name: str = (source)

Undocumented

admin_site = (source)

Undocumented

Undocumented

Undocumented

Undocumented

Undocumented

i18n_name = (source)

Undocumented

Undocumented