How to remove the link of subcat with no assigned products

Modules, Add-ons and custom code that's more than just a quick hack or Mod.
Post Reply
stam
Posts: 12
Joined: Fri Apr 01, 2011 8:51 pm
Location: Greece

How to remove the link of subcat with no assigned products

Post by stam »

Hi,
I would like to ask couple questions regarding SQL queries. As I have no experience in the field plz be gentle ;)

1. How can I remove the link of a subcategory (those displayed on the left side panel) when there are no products assigned to it;
(eg. lets say that I have in my store under Televisions category: 3 LCD's, 6 Plasma's and 0 CRT's and I want to display ALL 3 subcategories but only be able to browse those who have 1 or more products)

2. How can I display the no. of products for each subcategory ( e.g LCD (5) ).

Thank you in advance,
Stm.

P.S. I have been to this forum for just couple hours and I noticed that addressing questions directly is not the best practice to get an answer. Although it is only couple months since I have involved with the ISC and I have no alternatives except being an active member of this forum and study hard..
Martin
Site Admin
Site Admin
Posts: 1854
Joined: Wed Jun 17, 2009 6:30 pm
Location: South Yorkshire UK
Contact:

Re: How to remove the link of subcat with no assigned produc

Post by Martin »

Hey.. If someone has any ideas they will reply but you'll find tge best approach is often to dig around yourself, try to get some ideas of filenames affected, etc and report back.

The reasons for null replies are often down to folks not knowing or having the time to look (I'm in category 2) as much because ISC owners aren't generally code proficient and Interspire went out of their way to discourage community development.

As I said I'm stuffed for time but hopefully a couple of the others will chip in soon.
meules
Confirmed
Confirmed
Posts: 95
Joined: Wed Jun 17, 2009 8:56 pm
Location: NL

Re: How to remove the link of subcat with no assigned produc

Post by meules »

I'm working on a mod for number 2 ;)
ISC v6
meules
Confirmed
Confirmed
Posts: 95
Joined: Wed Jun 17, 2009 8:56 pm
Location: NL

Re: How to remove the link of subcat with no assigned produc

Post by meules »

For your first question You probably mean to do it automatically, but personally I think it's best to make the subcat imvisable in your admin area. Think that's best instead of fooling around in the code.
ISC v6
stam
Posts: 12
Joined: Fri Apr 01, 2011 8:51 pm
Location: Greece

Re: How to remove the link of subcat with no assigned produc

Post by stam »

Thanks for your response.
I have purchased the multi-vendor edition and I am only responsible for the administration of the store. Everything else is handle by the vendors selling their products within. So it is a matter of synchronization. How can I be sure when a vendor adds/removes a product in a specific category, without notify me? If you multiply this by the total no. of vendors (currently the store has just few, but in the near future the no. of vendors will increase) its becoming a messy situation where you end up with categories with no products or the other way around, not visible categories with assigned products. That is why I thought it is better if a category has no products, the link will be no linkable. It can't be hard to implement it. I have spend much time on it, I am sure I will come up with an acceptable solution..
Post Reply