X-Git-Url: https://git.mdrn.pl/prawokultury.git/blobdiff_plain/eec6aeb464e8966d1c27f8f6a67eb811170fa843..82c54fc0c49355b4a0ad05074caaccf0303eb965:/events/search_indexes.py diff --git a/events/search_indexes.py b/events/search_indexes.py index ec33c99..6b30345 100644 --- a/events/search_indexes.py +++ b/events/search_indexes.py @@ -5,7 +5,7 @@ from fnpdjango.utils.models.translation import add_translatable_index, localize_ from events.models import Event -class EventIndex(indexes.RealTimeSearchIndex, indexes.Indexable): +class EventIndex(indexes.SearchIndex, indexes.Indexable): text = indexes.CharField(null=True, model_attr=localize_field('title', settings.LANGUAGE_CODE), document=True) @@ -13,10 +13,6 @@ class EventIndex(indexes.RealTimeSearchIndex, indexes.Indexable): def get_model(self): return Event - def index_queryset(self): - """Used when the entire index for model is updated.""" - return self.get_model().objects.all() - add_translatable_index(EventIndex, { 'organizer': indexes.CharField(null=True),