News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

VirtueMart Products Module not filtering.

Started by snewpers, December 28, 2011, 14:02:25 PM

Previous topic - Next topic

snewpers

Heya

the 'VirtueMart Products' module does not filter correctly. I have multiple categories, and when I have more than one 'VirtueMart Products' module enabled it does not filter anything but the first active module eg:  On page 1 it should filter products of category 1, On page 2 (duplicate module) it should filter products from category 2, etc.

I have assigned the modules to the correct menus, but only the contents of 'page 1/category1' is displayed in all modules. So it seems that the modules load just fine (module header updates the name) but the products stay the same.

Any hints anyone?

--- ETA---
Seems that the module ignores category filtering. It also does not work correctly when 'latest products' is selected: it'll show the first 2 products.
When for instance 'Random' is selected, it'll show random images from the whole productrange, again ignoring any filtering.

Too bad.

PRO

#1


I have reported this bug

snewpers

#2
Cool, thank you for letting me know.
You have a link for your post so I can keep track of it?

Snewp.

ETA:

@BanquetTables.pro
You mentioned it's a category ID problem. Is that also the reason why 'top ten' and 'latest items' are showing the products with the lowest (oldest) ID, instead of the ones it *should* show?
If so, I can stop looking for the error I might have made ;)

patrickit

#3
For those of you still having this problem and cannot wait for the bug fix, I have solved it by doing the below:
In administrator/components/com_virtuemart/models/product.php
Look for around line 334
$where[] = 'p.`modified_on` > "'.$dateSql.'" ';

add after it
$orderBy = ' ORDER BY p.`modified_on`  ';   //PL temporary bug fix
$this->filter_order_Dir = 'DESC';   //PL temporary bug fix

See sample here: http://x-doria.ae/

I am using Joomla 1.7.3 virtuemart 2.0
That fixed my problem. I don't know how good the code is, or if it breaks anything else, it's working fine for me.
I adore Joomla & Virtuemart!

Milbo

Should I fix your bug, please support the VirtueMart project and become a member
______________________________________
Extensions approved by the core team: http://extensions.virtuemart.net/

patrickit

Hello Milbo,

Haven't tried 2.0.1, I have 2.0.0 according to my VM control panel.
So far it is working great so I won't upgrade now.

Amazing product.

Thanks!!
I adore Joomla & Virtuemart!

brentonking

I grabbed the .php files from the 2.0.1 pre-release (mod_virtuemart_product) but didn't make any difference, the categories still don't filter proper. Is there another file(s) I need to change instead?

patrickit

Brentonking,

My solution just solves the latest products problem, it does not solve the category filter one. I haven't tried fixing the category filter as I hadn't needed this feature.
If you want the best sellers to work then I have a workaround too.
I adore Joomla & Virtuemart!

brentonking

partickit,

Yep, I did realise that. I just noticed the original post had also mentioned the category filter issue. And I was just following up on that. Wasn't expecting your fix to work for it, was more trying to give a secondary answer to Milbo's question regarding 2.0.1.

brentonking

Update: 2.0.1 D fixes the category filtering issue! Nice work VM team!

patrickit

Mole_LR updates us that VM 2.0.1e does not fix the latest products, best seller problem in the product module http://forum.virtuemart.net/index.php?topic=97284.msg322174#msg322174
I adore Joomla & Virtuemart!