Fix fees total

This commit is contained in:
2012-07-10 21:40:27 +01:00
parent 58c0f9554e
commit de53293c3f

View File

@@ -17,7 +17,7 @@ class Command(BaseCommand):
for total in MonthTotal.objects.filter(charged=False):
if datetime.datetime(total.year, total.month, calendar.monthrange(total.year, total.month)[1], 23, 59, 59, tzinfo=utc) < now():
print "Charging %s - %s/%s" % (total.corporation, total.year, total.month)
total.corporation.balance -= Decimal(str(self.object.fees_due))
total.corporation.balance -= Decimal(str(total.fees_due))
total.charged = True
total.save()