Hello,

I have this product model

class Product(models.Model):
    VAT_CODES = (
        (6.00, '6%'),
        (12.00, '12%'),
        (21.00, '21%'),
    )
    description = models.CharField(max_length=50,)
    unit_price = models.DecimalField(max_digits=10,decimal_places=2)
    vat_code = models.DecimalField
(max_digits=4,decimal_places=2,choices=settings.VAT_CODES,)
    # vat_code = models.CharField
(max_length=7,choices=settings.VAT_CODES,)

But when I try the admin interface the vat_code combobox give all
dashes when I will change the product vat_code.
The vat_code have the right value in the database. There is no problem
when I change from DecimalField to CharField see the line in comment.

Any idea what could be the problem ?

Kind Regards
James


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to