def __init__(self, attrs=None, choices=(), **kwargs):
self.choices = choices<EOL>if attrs is not None:<EOL><INDENT>self.attrs = attrs.copy()<EOL><DEDENT>else:<EOL><INDENT>self.attrs = {}<EOL><DEDENT>self.data_view = kwargs.pop('<STR_LIT>', None)<EOL>self.data_url = kwargs.pop('<STR_LIT>', None)<EOL>dependent_fields = kwargs.pop('<STR_LIT>', None)<EOL>if dependent_fields is not None:<EOL><INDENT>self.dependent_fields = dict(dependent_fields)<EOL><DEDENT>if not (self.data_view or self.data_url):<EOL><INDENT>raise ValueError('<STR_LIT>')<EOL><DEDENT>self.userGetValTextFuncName = kwargs.pop('<STR_LIT>', '<STR_LIT:null>')<EOL>
Return HeavySelect2Mixin.

Args:
    data_view (str): URL pattern name
    data_url (str): URL
    dependent_fields (dict): Dictionary of dependent parent fields.
        The value of the dependent field will be passed as to :func:`.filter_queryset`.
        It can be used to further restrict the search results. For example, a city
        widget could be dependent on a country.
        Key is a name of a field in a form.
        Value is a name of a field in a model (used in `queryset`).