Announcement

Collapse
No announcement yet.

Dynamically Set "Sale" Flag on Product Listings

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Dynamically Set "Sale" Flag on Product Listings

    Is it possible to determine whether a given item is part of any active sale to dynamically set a "sale" flag on the product listing? I know I could look at the price vs the base price, but we have volume pricing on a lot of items so that won't work for us since that would trigger as soon as the customer starts adding those items to their basket. I get the feeling that might force a really manual process but I'm hoping I'm wrong.

    Any thoughts or suggestions?

    #2
    It's possible to write code that will check a product to see whether it's assigned to certain types of price groups. E.g. the on-sale flag can be triggered only by price groups that have an expiration date. I'm not sure offhand if this can be done just with template code; but if not, a small custom module can do it. You can drop me a line if you'd like a quote for this.
    Kent Multer
    Magic Metal Productions
    http://TheMagicM.com
    * Web developer/designer
    * E-commerce and Miva
    * Author, The Official Miva Web Scripting Book -- available on-line:
    http://www.amazon.com/exec/obidos/IS...icmetalproducA

    Comment


      #3
      After playing with it through the afternoon a bit, I went ahead and created a semi-manual way to do this. There is code that allows getting price group data, testing whether it's currently running, and testing whether an item is in that price group, but you have to call it with the name of the price group. Since I have several price groups to test against, I created an array and looped through it. It will require manually updating that array of price groups periodically, but I guess that's not the end of the world.

      Comment

      Working...
      X