divio / aldryn-search

Haystack 2.0 search index for django CMS
Other
48 stars 78 forks source link

limit search to results from current site_id only? #88

Open benzkji opened 6 years ago

benzkji commented 6 years ago

when running multiple sites in one django CMS instance, results are displayed from all sites. resulting in 404s for results from other sites. I can see there is already a site_id field on the search index, so this could be done in here https://github.com/aldryn/aldryn-search/blob/master/aldryn_search/views.py#L62 , probably without much hassle?

If wanted at all? One issue could be, if one has other indexes, without the site_id field.