Commit a035abb3 authored by alexAubin's avatar alexAubin

Fix an issue with bills when manually adding payments

parent 2b799c44
......@@ -142,7 +142,7 @@ class Bill(models.Model):
"Creating draft bill DRAFT-{} (Member: {}).".format(, self.member))
if not self.validated:
if hasattr(self, 'validated') and not self.validated:
"Updating draft bill DRAFT-{} (Member: {}).".format(, self.member))
......@@ -738,7 +738,7 @@ def reconcile_bills_and_payments(member):
# If this payment is to be allocated for a specific bill...
if p.bill:
# Assert that the invoice is still 'active'
assert p.bill in active_bills
assert in [ for b in active_bills]
i = p.bill
"Payment is to be allocated specifically to bill {}".format(
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment