On Oct 3, 6:23 am, Alessandro <[EMAIL PROTECTED]> wrote:
> Whitespaces are generated by \n inside if statements when if = true.
> try to see what returns if.discount inside shell, maybe the problem is there.
>
> http://www.java2s.com/Code/Python/Data-Type/WhatsTrueinPython.htm
>
> #      0 is false; all other numbers are true.
> #      An empty string ("") is false, all other strings are true.
> #      An empty list ([]) is false; all other lists are true.
> #      An empty tuple (()) is false; all other tuples are true.
> #      An empty dictionary ({}) is false; all other dictionaries are true.

Here's what I get in a shell:

In [8]: Order.objects.get(id=14).discount
Out[8]: Decimal("0E-10")

In [10]: Order.objects.get(id=14).is_shippable
Out[10]: False

In [11]: Order.objects.get(id=14).tax
Out[11]: Decimal("0E-10")

The second statement is false and it seems to me the first and third
should be false too.

Any other ideas?

--~--~---------~--~----~------------~-------~--~----~
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