After looking into this a bit here is what I have noticed:
the truncate_decimal filter while working just fine, does not always
return a decimal number. If you pass in a number in scientific to
truncate_decimal it will return a truncated number in scientific
notation, for example:
truncate_decimal("2E+1") yields Decimal("2E+1") with then turns into
string "2E+1" which is incorrect on the PayPal form.
this is not always the case, for instance:
truncate_decimal("2.1223E+1") yields Decimal("21.23")
Perhaps truncate_decimal should be altered to never return a number in
scientific notation. This will solve the immediate issue with the
PayPal form and all other templates in Satchmo. The underlying problem
of values in models being stored in scientific notation is another
issue.
This should probably be a ticket...
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---