Show amount of products

ragou

Avatar: ragou

2009-03-14 20:11

I am trying to use Q.Cart as classifieds. Os ot posible in Categories to show the amount of products. Somethig like this:

Categories
Cars (16)
TV (2)
etc.
Thank you

» Quick.Cart v3.x

beholder

Avatar: beholder

2009-03-15 20:03

this would be a nice feature to add to a new QC version. I'll get back to you later, this seems very simple to do. SEEMS.

beholder

Avatar: beholder

2009-03-15 23:15

I was unable to do this quickly, it's something with objects that I don't understand. I'll let this up to Treewood to unfold.

Again, I think this shouldn't be too difficult to program, three-four lines of code max.

beholder

Avatar: beholder

2009-03-16 13:22

Treewood, please?

beholder

Avatar: beholder

2009-03-17 15:10

pretty please? :-)

treewood (OpenSolution)

Avatar: treewood

2009-03-18 07:54

this will not be few lines of code becase:
1. product could be in unlimited categories
2. categories have subcategories but in main category should be ammount products of all subcategories

beholder

Avatar: beholder

2009-03-18 23:49

I agree with both of your points. HOWEVER, there is a finite number of products for any given category. Also, yes, IMO the main categories should have all products counted, even if they belong to their subcategories.

I got as far as getting the right IDs of the given categories (that was the easy part) but I am having a problem because there is no function countProductsOfPage() or an equivalent. I have only the generateProductsListArray() ------- but in function throwMenu() I can't figure out for some stubborn reason how to generate products list array for other categories than $iPageCurrent. This would be SO easy otherwise.

Back to top
about us | contact