diff --git a/billard/models.py b/billard/models.py index d0cb5bf..e39fdad 100644 --- a/billard/models.py +++ b/billard/models.py @@ -47,7 +47,7 @@ class Client(models.Model): desk2_prize_ht = models.DecimalField(max_digits=4, decimal_places=2, blank=True, null=True) def accounting_for(self, desk_no): - return Accounting.objects.filter(location=self.location, desk_no=desk_no)[:2][::-1] + return Accounting.objects.filter(location=self.location, client_id=self.id, desk_no=desk_no)[:2][::-1] def accounting_1(self): return self.accounting_for(1)