Jump to content

Invalidate cache after price change


Recommended Posts

Hi guys,

 

I hope that's the right place to address my question. I use a PS 1.7.x with a 3rd party template (+ modules). The following issue happens using the Smarty Cache (configured as: delete on all changes, any template option affected in the same way).

 

The steps I executed:

1. I have a special price set up for an article. That is shown correctly on the frontend (there is a special price template coming with that theme). 

2. I adjust that price to a different value (e.g. 5€ to 10€ by removing the special price and adding a new one).

3. The frontend still shows me the old special price - there seems to be no way except deleting the cache manually.

 

My questions:

1. How should the Cache be invalidated correctly? Is that triggered by PS on change or should the theme module figure that out?

2. If each module has to figure that out - what would you recommend in order to detect a change between latest data and Cache?

3. Assuming it can be figured out, is the _clearCache(templateName, ...) function in the Module class the preferred way for clearing the cache for a template?

 

My background: I am developer but not yet very familiar with the PS code/architecture.

 

I appreciate any help.

 

best regards,

 

Jens

Edited by jenswl (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...