This backend assumes that every indexed model is multilingual. So for a given object all index entries share the same django-id.
This doesn't work for apps where the language is filtered on the manager level (i.e. the model has a language attribute).
Unfortunately the environment language is not set when haystacks index_queryset is evaluated.
A possible solution for this is a decorator class that wraps the queryset returned by index_queryset and filters it as soon as the language is available.
Haystack does slice the queryset before the language filtering can happen.
This backend assumes that every indexed model is multilingual. So for a given object all index entries share the same django-id.
This doesn't work for apps where the language is filtered on the manager level (i.e. the model has a
languageattribute).Unfortunately the environment language is not set when haystacks
index_querysetis evaluated.A possible solution for this is a decorator class that wraps the queryset returned by
index_querysetand filters it as soon as the language is available.Haystack does slice the queryset before the language filtering can happen.