Browse Source

Use more digits for payment amounts and member balance (otherwise can't handle payment more than 999)

Alexandre Aubin 7 years ago
parent
commit
8344913d48
2 changed files with 2 additions and 2 deletions
  1. 1 1
      coin/billing/models.py
  2. 1 1
      coin/members/models.py

+ 1 - 1
coin/billing/models.py

@@ -364,7 +364,7 @@ class Payment(models.Model):
                                     default='transfer',
                                     choices=PAYMENT_MEAN_CHOICES,
                                     verbose_name='moyen de paiement')
-    amount = models.DecimalField(max_digits=5, decimal_places=2, null=True,
+    amount = models.DecimalField(max_digits=6, decimal_places=2, null=True,
                                  verbose_name='montant')
     date = models.DateField(default=datetime.date.today)
     invoice = models.ForeignKey(Invoice, verbose_name='facture associée', null=True,

+ 1 - 1
coin/members/models.py

@@ -96,7 +96,7 @@ class Member(CoinLdapSyncMixin, AbstractUser):
                         blank=True,
                         verbose_name="Date du dernier email de relance de cotisation envoyé")
 
-    balance = models.DecimalField(max_digits=5, decimal_places=2, default=0,
+    balance = models.DecimalField(max_digits=6, decimal_places=2, default=0,
                                   verbose_name='account balance')