Hi,

I needed that functionality as well. I ended up using is adding a second price 
for the product with an expiration date then in my template I check for that 
price.
"""
{% if product.get_qty_price_list.1.1 %} 
        <span style="text-decoration: line-through;">{{ 
product.get_qty_price_list.0.1|currency }}</span>
        &nbsp;
        <span style="color:red;">{{ product|discount_price:sale|currency 
}}</span>      
{% else %}
        {{ product|discount_price:sale|currency }}
{% endif %}
"""

Hope it helps.

Laszlo
http://twitter.com/LZAntal



On Oct 16, 2012, at 7:10 AM, Stanislav Mihaylov <[email protected]> wrote:

> Hello Scott, I was wondering did you manage to develop this template tag 
> after all ? I am trying to implement sales for particular products without 
> discount code too...
> 
> On Wednesday, July 28, 2010 11:49:39 PM UTC+1, John-Scott wrote:
> On Jul 28, 5:41 pm, Brian Lee <[email protected]> wrote: 
> > How can I place a product on Sale so that the below code's if case is 
> > triggered (from default product template)? 
> > 
> > I thought it would be to have two prices with one having expiration 
> > date. But that is not the case. 
> > 
> >         {% if sale %}<strike id="fullprice" style="display: 
> > block;">{{ product|discount_price:""|currency }}</strike>{% endif %} 
> >         <span id="price">{{ product|discount_price:sale|currency }}</span> 
> > 
> > Where do I need to look to see how {% if sale % is triggered? 
> 
> Proper 'sales' as normally understood (30% off Brand X, no discount 
> code required) are not directly supported in Satchmo as best as I can 
> tell. 
> 
> The 'sale' template tag returns an actual Discount code object if and 
> only if there is an automatic discount (aka store wide sale). See [1] 
> for the relevant criteria used for selecting a Discount as 'sale'. 
> 
> No other types of Discounts or temporary price reductions will 
> automatically show up for this template tag. I'm am currently trying 
> to work out a template tag which will cover all cases, but it's a 
> beast. 
> 
> [1] 
> http://bitbucket.org/chris1610/satchmo/src/0bd6df5821d2/satchmo/apps/product/utils.py#cl-26
> 
> -- 
> You received this message because you are subscribed to the Google Groups 
> "Satchmo users" group.
> To view this discussion on the web visit 
> https://groups.google.com/d/msg/satchmo-users/-/LAsanoCSTA0J.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to 
> [email protected].
> For more options, visit this group at 
> http://groups.google.com/group/satchmo-users?hl=en.

-- 
You received this message because you are subscribed to the Google Groups 
"Satchmo users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/satchmo-users?hl=en.

Reply via email to