Ignore stores without a geo location from the search index.

This commit is contained in:
2013-04-08 21:42:53 +01:00
parent 20c04ee65e
commit f5d064ffac

View File

@@ -12,4 +12,4 @@ class StoreIndex(indexes.SearchIndex, indexes.Indexable):
def index_queryset(self, using=None):
"""Used when the entire index for model is updated."""
return self.get_model().objects.filter(active=True)
return self.get_model().objects.filter(active=True).exclude(geo_latitude=None)