]> git.parisson.com Git - teleforma.git/commitdiff
add limit
authorGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Wed, 1 Dec 2021 10:30:11 +0000 (11:30 +0100)
committerGuillaume Pellerin <guillaume.pellerin@ircam.fr>
Wed, 1 Dec 2021 10:30:11 +0000 (11:30 +0100)
teleforma/management/commands/teleforma-copy-students.py

index 35775bef3e68bda1901ef8c064cc937f8dad9341..d18438ddf6e7b963b842d8aa4ac8c51c990a75bb 100644 (file)
@@ -92,7 +92,7 @@ class Command(BaseCommand):
                 if date_paid:
                     if payments_to:
                         payment_to = payments_to[0]
-                        if date_paid != payment_to.date_paid:
+                        if date_paid != payment_to.date_paid and date_paid >= date_limit:
                             payment_to.online_paid = payment.online_paid
                             payment_to.date_paid = payment.date_paid
                             payment_to.save()