This query is only to get the appropriate Categories & Subcategories. There
are 5 Categories and 45 Subcategories.
My products are imported from webshops which are using different categories
for the same things ("tshirt", "t-shirts", "t-shirt", "short sleeved
shirts" may all be the same). To cope with this issue I have the
"Resellercategories" that I relate to a specific Category and Subcategory.
Category/Subcategory -> Resellercategory -> Product
(Resellercategories are never seen in the frontend)
If I filter the products for "male" I only want to display (non-empty)
Categories/Subcategories that have male products.
To answer your question, there is no pagination on the Categories and
Subcategories that I'm fetching here with this query. The query only
returns the appropriate Categories/Subcategories. So if filtered by "male"
it returns 3 Categories and 12 Subcategories (In my dev environment).
I am using pagination for the actual products though, but that is a
separate query.
--
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Talk" group.
To view this discussion on the web visit
https://groups.google.com/d/msg/rubyonrails-talk/-/ZGBq4G24MIUJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.