Hi,

I tried to change queryset in BaseInLineformset but I got this error: 
*metaclass 
conflict: the metaclass of a derived class must be a (non-strict) subclass 
of the metaclasses of all its bases*
*
*
Here my code:

def BaseItensInlineFormSet(BaseInlineFormSet):
    def __init__(self, *args, **kwargs):
        super(BaseItensInlineFormSet, self).__init__(*args, **kwargs)
        self.queryset = ItensPedido.objects.select_related()

def BaseItensInlineFormSet(BaseInlineFormSet):
    def __init__(self, *args, **kwargs):
        super(BaseItensInlineFormSet, self).__init__(*args, **kwargs)
        self.queryset = ItensPedido.objects.select_related()


Here is my traceback: http://pastebin.com/GVfzzLYW

I get this code from Django 
docs: 
https://docs.djangoproject.com/en/1.5/topics/forms/modelforms/#changing-the-queryset

Why I got this error? How I fix them?


Regards,

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to