we are building our first small Merchello prototype because we think it has huge potential.
We need a multi-store (aka umbraco multi-node) tree structure, where each root node represents a city store. The price of each product should depend on the store.
For this purpose we are using MerchelloHelperProductDataModifiers task chain, but our custom task (which modifies the price) runs only the very first time the customer visits the product page. Every following request for the same product does not call our task.
Is there any caching on the MerchelloHelperProductDataModifiers task chain? How could we deal with it?
I can see in your use case that it may be too restrictive, but for the 99% I think it's probably appropriate.
I think the appropriate way to make this work with the flexibility you need is to optionally allow for an optional additional key (or perhaps even array that could be joined) when creating the key so that the modifiers don't have to execute every single time.
In your case this might be an individual store alias or something ...
MerchelloHelperProductDataModifiers task chain
Hi Rusty,
we are building our first small Merchello prototype because we think it has huge potential.
We need a multi-store (aka umbraco multi-node) tree structure, where each root node represents a city store. The price of each product should depend on the store.
For this purpose we are using MerchelloHelperProductDataModifiers task chain, but our custom task (which modifies the price) runs only the very first time the customer visits the product page. Every following request for the same product does not call our task.
Is there any caching on the MerchelloHelperProductDataModifiers task chain? How could we deal with it?
Thanks, Alessandro
We found the caching system on VirtualContentCache class, so we switched to a new variant-per-store approach.
Anyhow, don't you think that
is a bit too restrictive?
For example, think of different prices per user role, which is quite common in both B2B and B2C scenarios.
Hey Alessandro,
I can see in your use case that it may be too restrictive, but for the 99% I think it's probably appropriate.
I think the appropriate way to make this work with the flexibility you need is to optionally allow for an optional additional key (or perhaps even array that could be joined) when creating the key so that the modifiers don't have to execute every single time.
In your case this might be an individual store alias or something ...
what do you think?
It'd be a great pull request!
is working on a reply...