VirtueMart Forum

VirtueMart 2 + 3 + 4 => Administration & Configuration => Topic started by: Tryer on December 06, 2018, 10:08:34 AM

Title: Two Virtuemart Category Modules
Post by: Tryer on December 06, 2018, 10:08:34 AM
I am using Joomla 3.9.1, PHP 7.2 and Virtuemart 3.4.2.

I have published two copies of the Virtuemart categories module with different parent categories and mutually exclusive assignments. They are published (obviously at mutually exclusive times) in the same module position. Hence they never both appear on the same page. However, there appears to be some conflict between the two modules which produces unpredictable results.

Am I trying to do the impossible?

Comments appreciated.
Title: Re: Two Virtuemart Category Modules
Post by: GJC Web Design on December 06, 2018, 10:14:29 AM
need more info..  what conflicts?

I know some states are saved in the session so will be applied to any VM cat selection but haven't looked if this affects the modules
Title: Re: Two Virtuemart Category Modules
Post by: Tryer on December 06, 2018, 20:14:44 PM
Thanks for the reply.

The conflicts are difficult to define because the logic of the situation is certainly complicated. But, basically, the modules will load correctly and look fine, but then when the user starts using the links the result get unpredictable. For instance, clicking on a link may reveal other links that are part of the second (supposedly unpublished) module only. How that can happen when the two modules have mutually exclusive assignment I do not know. There must be a conflict.

Incidentally, the conflict situation also generates a Geocode error from the Google maps module on my site. Unpublish the categories modules and the Geocode error disappears! Wow - it drives me mad! I am tempted to conclude that I am trying to achieve the impossible.

Actually, all I am trying to do is as follows. I have two categories of product. I want non-logged-in visitors to see only one of the categories. Logged-in visitors should see both categories. It sounds simple doesn't it?! I started out with shopper groups and this worked basically, but of course left the forbidden categories displayed with no products. Also, for non-logged-in guests, the categories module displayed the forbidden categories avaiable only to logged-in guests!

There must be a simpler way of doing all this.
Title: Re: Two Virtuemart Category Modules
Post by: PRO on December 06, 2018, 21:34:06 PM
do you get the same problem with different positions?
Title: Re: Two Virtuemart Category Modules
Post by: Studio 42 on December 07, 2018, 03:02:43 AM
Virtuemat ALWAYS use a cache for categories tree, so perhaps the problem is because the cache.
Have you try other categories module?
Title: Re: Two Virtuemart Category Modules
Post by: Tryer on December 09, 2018, 17:43:40 PM
Thanks for your reply.

Yes, it is the same with different positions. I have given up hope of ever getting this to work and have consequently abandoned the Virtuemart Categories module. I have replaced it with a commercial VM Categories module which exhibits no such conflicts in the same setup. So I now have this working although I have gone around the problem rather than solve it.

Thanks to all for the help.