Searching with aggregations

The user interaction that we would like to have is this: the user opens the search page or does a search and sees the list of category links. The user then clicks on one of those links and sees only products from those categories, with the user's previous search applied. So if the user searched for products with price between 100 and 200 and then clicked on one of the category links, the new search should show only products from that category while still applying the price filtering.

In order to achieve this, we need a way to create the category links so that the current search is preserved. We can pass the category to HomeView as another GET parameter. So we need to take the current GET parameters (which make up the ...

Get Django Project Blueprints now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.