Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Catalog navigation and Search (OCC-192) #351

Closed
agriffard opened this issue Sep 16, 2023 · 4 comments · Fixed by #374
Closed

Catalog navigation and Search (OCC-192) #351

agriffard opened this issue Sep 16, 2023 · 4 comments · Fixed by #374
Assignees

Comments

@agriffard
Copy link
Member

agriffard commented Sep 16, 2023

One of the most important feature of an ecommerce site is to allow to find a specific product easily.

You should be able to organize your products by hierarchical categories (i.e Taxonomies) in order to navigate in the catalog (Autoroute parent path, Breadcrumbs, ...).

A listing of products have to offer multiple sorts (Lower to higher price, Higher to lower price, most recent, featured, ...).

It would be also really useful to provide an advanced faceted search (Filter by multiple criteria: Price range, variants, Brand)

Jira issue

@github-actions github-actions bot changed the title Catalog navigation and Search Catalog navigation and Search (OCC-192) Sep 16, 2023
@barthamark barthamark self-assigned this Sep 26, 2023
@barthamark
Copy link
Contributor

barthamark commented Oct 13, 2023

My initial thought was to utilize the Lists feature and use ListPart somehow. However, it appears that the querying logic behind ListPart is not extensible in the sense that we can't really tap into the query to filter by different attributes. To address this, I'm considering creating a ProductListPart that initiates a Product query. An IProductFilterProvider could then tap into this for filtering. For example, a filter provider would check for the presence of a relevant query string and add the criteria accordingly. As for adding the query string, we can create a few built-in widgets for this, but essentially, it's up to the developer. Please let me know your thoughts; otherwise, I'll go ahead and build the infrastructure for this.

@sarahelsaig
Copy link
Contributor

That's a good approach. Create a context for the filter parameters, the query object, and the result too (from previous experience I'm certain eventually we'll need both online and offline filtering) so we can chain multiple providers. We'd probably need separate index providers for each kind of filterable criteria and then they can be joined to the query by the filter providers.

Price is a huge question, because people often want the ability to sort by price, but price can vary based on the user, especially with discounts, so I'm not sure how well that can be indexed.

I think the filter widget can be made a followup issue, so for now it's enough if the query string s work.

@barthamark
Copy link
Contributor

In my opinion it'd make sense to create at least a few widgets to make the feature actually usable. I was thinking about a filter for the product attributes and maybe an order by widget (order by price and title). At least something basic that can be extended in a separate issue based on feedback.

@sarahelsaig
Copy link
Contributor

Most important is to have a title/fulltext search widget. Every other widget beyond that is a bonus.

For the product attributes, eventually I'd like to have the filter provider populate a list of models based on the field settings, so we can automatically generate something like the sidebar you see on Amazon or Árukereső. That would be a single widget with one shape for each filter so they can be shape-overridden by type or by name if needed. This is why I wrote that it can be a followup issue. If you want to have something simpler as a temporary solution, that's fine.

I think "order by" should be part of the product list part rather than a widget. After all, it's always above/below the product list, usually right next to the pager. (e.g. both pager and sorting could be separate shapes displayed by the part's driver)
Either way, the available "order by" options should be populated by the filter providers to keep it modular.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants