Welcome to the MetaMod and Chameleon Support Forums.

Before posting, please check out the FAQs.

helpme

 

Need extra help with your Joomla site? Consider paid Joomla support by the developer of Chameleon and MetaMod.

 

Customers limited to making purchases in a certain time frame

Customers limited to making purchases in a certain time frame

Hi,

I want to "close"my virtuemartshop for a certain timeframe the shop should be "open" for bussiness from friday 1400 til mondaymorning 800  how do i do that?

thx in advance greetz Edensan

edensan
Beginner Modder
ranks
useravatar
Offline
5 Posts
Administrator has disabled public posting

Re: Customers limited to making purchases in a certain time frame

Hi Edensan,

that's a good question. It really depends on exactly how you want the shop to act when it's not "open for business". Should the products be visible at all? Should they be visible but no "add to cart" functions? Or just remove all links to cart and checkout? Maybe you also want some sort of banner appearing telling people that the shop is closed.

Can you describe in more detail how you want the "closed shop" to act?

Regards,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3328 Posts
User info in posts
Administrator has disabled public posting

Re: Customers limited to making purchases in a certain time frame

hi stephen,
thy for look into it!

i would love the idea of showing the products only
but a simple page sorry we are closed from monday 800 till Friday 1400  is fit for the job also.
key thing is in that timeframe no orders are made.

greetz Edensan

edensan
Beginner Modder
ranks
useravatar
Offline
5 Posts
Administrator has disabled public posting

Re: Customers limited to making purchases in a certain time frame

Hi,
i was searching for other options to "close" the shop in a certain timeframe
into cataloge mode in a certain timeframe would be a verry good option for me.


gr Edwin

edensan
Beginner Modder
ranks
useravatar
Offline
5 Posts
Administrator has disabled public posting

Re: Customers limited to making purchases in a certain time frame

Hi Edwin,

I'm just doing some testing to see if Chameleon is able to force VM into catalog mode. If it can do this then it's an easy setup. Stand by...

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3328 Posts
User info in posts
Administrator has disabled public posting

Re: Customers limited to making purchases in a certain time frame

Ok, here's how to force VM into Catalog mode as a result of a Chameleon rule succeeding. This is clever! Note that this cannot work in MetaMod, only in Chameleon.

Put this into the PHP box in the Succeed Action in a rule:

if (!class_exists( 'VmConfig' )) require(JPATH_ROOT.'/administrator/components/com_virtuemart/helpers/config.php');
VmConfig::loadConfig();
$rProperty = new ReflectionProperty("VmConfig", '_jpConfig');
$rProperty->setAccessible(true);
$config = $rProperty->getValue();
$config->_params['use_as_catalog'] = 1;

Of course, the rest of the rule needs to be detecting the right time span as well. So you could use the following PHP in the PHP box on the main tab (not the one in the Succeed action) :

if ($core_genius->inTimeSpan("fri 14:00 - mon 08:00")) return false; // rule fails during these times, hence not in catalog mode
else return true; // rule succeeds outside of those times, hence set to catalog mode


So put those 2 sets of things into 1 Chameleon rule, name it, save it, and hey presto you have Catalog mode enabled when not between fri 14:00 and mon 08:00.

Best regards,
Stephen

Stephen Brandon
MetaMod / Chameleon developer
If you use MetaMod or Chameleon, please post a rating and a review at the Joomla! Extensions Directory: Chameleon | MetaMod

metamodguy
useravatar
Offline
3328 Posts
User info in posts
Administrator has disabled public posting

Re: Customers limited to making purchases in a certain time frame

hi,

your a wizzard!!

edensan
Beginner Modder
ranks
useravatar
Offline
5 Posts
Administrator has disabled public posting

Board Info

Board Stats:
 
Total Topics:
1679
Total Polls:
6
Total Posts:
5933
Posts this week:
3
User Info:
 
Total Users:
4421
Newest User:
rajajudi14
Members Online:
0
Guests Online:
109

Online: 
There are no members online

Forum Legend:

 Topic
 New
 Locked
 Sticky
 Active
 New/Active
 New/Locked
 New Sticky
 Locked/Active
 Active/Sticky
 Sticky/Locked
 Sticky/Active/Locked