VirtueMart Forum

VirtueMart 2 + 3 + 4 => Virtuemart Development and bug reports => Topic started by: xenofon on September 22, 2016, 16:32:51 PM

Title: My top ten products never update !
Post by: xenofon on September 22, 2016, 16:32:51 PM
Hi Virtuemart forum,

I am running an eshop you can find it here: https://lapop.gr

My problem is that my top ten section of Virtuemart home page is not updating, NEVER !
I read somewhere that the Order status of an order must be "Shipped" to auto update the Top ten Products page, is this true?
So i've started to turn all my order statuses of my delivered orders to "Shipped" .... but ... nothing changed, my Top ten Products page is stuck!
What's the solution for that problem, dows anyone in here can help me fix that ?

Thank you in advance,
Xenofon Kaloudis
Title: Re: My top ten products never update !
Post by: Milbo on September 22, 2016, 17:47:27 PM
It works with

case 'topten':
$orderBy = ' ORDER BY p.`product_sales` DESC, `virtuemart_product_id` DESC';
$where[] = 'pp.`product_price`>"0.0" ';


product_sales is updated by any order update. So you can check our order stati, it should increase, at least, when it is set to confirmed. Consider that there are different caches. There is a joomla cache for modules and a vm cache within the module. This is to prevent that for example featured products change any page call. So check also your cache config (in joomla and in the module itself)
Title: Re: My top ten products never update !
Post by: xenofon on September 23, 2016, 12:43:10 PM
Hi Milbo,

FIrst of all thank you for the quick reply.
Secondly you gave me a code that as i can think should be provided to a .php file. Which is this file ? - You didn't mention so that i can test if it'll work.

"Consider that there are different caches. There is a joomla cache for modules and a vm cache within the module. This is to prevent that for example featured products change any page call. So check also your cache config (in joomla and in the module itself)" - I can not understand what you want to say me here. Please specify that to me.

Thank you.
Title: Re: My top ten products never update !
Post by: GJC Web Design on September 23, 2016, 13:12:43 PM
the code is only showing u HOW the top ten are found.. by sales

make sure your not caching things you shouldn't ->  experiment
Title: Re: My top ten products never update !
Post by: xenofon on September 23, 2016, 15:20:55 PM
Hi,

Excuse me but i can not undestrand exactly where should i look.
Please guide me somehow to find the setting that i should look.

Title: Re: My top ten products never update !
Post by: jenkinhill on September 23, 2016, 18:15:47 PM
!!!   https://docs.joomla.org/Cache

Title: Re: My top ten products never update !
Post by: Milbo on September 23, 2016, 18:26:53 PM
In the basic options is additionally the VM-cache. It uses also the joomla cache module, but with another time. So you can use for the module for example 2 minutes.
Title: Re: My top ten products never update !
Post by: xenofon on September 26, 2016, 16:27:14 PM
Hi,

I do not know if this helps, i will post you some attachments to see my backend system.

You can see here the settings i have in my "Global Configuration -> System tab" (Attachment photo1)

Now look at my module "Virtuemart Products" at "Type column" my settings of each tab inside the momdule (Module tab - photo2 , Menu Assignment tab - photo3 , Module Permissions tab - photo4 , Advanced tab - photo5)

Waiting for your response.
Title: Re: My top ten products never update !
Post by: xenofon on September 28, 2016, 11:21:11 AM
Hi,

Someonne respond me please. I attached some screenshots to help ...

Thanks
Title: Re: My top ten products never update !
Post by: GJC Web Design on September 28, 2016, 13:13:43 PM
have you checked IF the product_sales is changing in your tables? 
Title: Re: My top ten products never update !
Post by: xenofon on September 28, 2016, 15:17:16 PM
You mean my database tables ? Which tables are you asking me ?
Title: Re: My top ten products never update !
Post by: jenkinhill on September 28, 2016, 17:08:28 PM
Use phpMyAdmin to check entries in checking product_sales in  ###_virtuemart_products

The product with most sales is in first position of the top ten etc.....
Title: Re: My top ten products never update !
Post by: xenofon on September 29, 2016, 11:19:24 AM
Hi,

I found column " product sales" in table "virtuemart_products" and i sorted my "product sales" column . I also saw a column "product_ordered" which makes more sense to me for updating my "top ten products". The case is that none of my top listed products are also shown to frontend. Frontend is stuck months now. At this point i want to inform you (i do not know if it is having any role to my problem) that my eshop is using stockable variants for every product. That means that if i have a product (parent) that's name is XXX and has 3 colors (black,red,white) and 3 sizes (Small, Medium,Large) then, in my system will be created 9 child products which will have for example the following sku's (Main Names are the same every time):

1)XXX-SBLACK
2)XXX-MBLACK
3)XXX-LBLACK
4)XXX-SRED
5)XXX-MRED
6)XXX-LRED
7)XXX-SWHITE
8)XXX-MWHITE
9)XXX-LWHITE     , these are my childs. These are childs of the parent product XXX

Child products are not shown to front end cause Virtuemart's function "Show uncategorised child products in search results and modules " is uncheked and all my child products are not categorized, only my parent ones are categorized.
You can see that Ajax is calling my child products after the shoppers click on an attribute of a product, and after that he can see the variant as SKU in the cart section, as me who i am sending tthe delivery.

I do not know if this explanation helps. We must find a solution. The image of my Top Ten products is completely wrong. We must fix that.

Waiting for reply. Thank you all in here
Title: Re: My top ten products never update !
Post by: Milbo on September 29, 2016, 12:56:50 PM
vm2?
Title: Re: My top ten products never update !
Post by: xenofon on September 29, 2016, 13:00:15 PM
Sorry, i forgot to post these info.

Joomla : 3.5.1
Virtuemart: 3.0.9.4
Title: Re: My top ten products never update !
Post by: xenofon on October 03, 2016, 11:59:11 AM
Hi,

Any answer yet ?
Do we have anything about my case ?
Title: Re: My top ten products never update !
Post by: teddyfresco on October 04, 2016, 09:23:45 AM
Xenofon, did you try updating your environment to last Joomla and VM? Yours are more than a year old, maybe some bug has already been squashed...
Title: Re: My top ten products never update !
Post by: xenofon on October 04, 2016, 09:56:30 AM
Hi, i can not try that right now as i have problem setting my website to localhost for testing such things .....
I have a problem with Akeeba that i i am trying to solve, with no success by now ..
The restore of site files and Database is ending greate but after that, when i hit the url for localhost the site is not responding ... NOthing is shown , website not exists.
That's what i am trying to solve right now ....