8
0
Fork 0
mirror of https://gitlab2.federez.net/re2o/re2o synced 2024-11-24 04:13:12 +00:00

Fix: Deposit creation form when no deposit items exist

This commit is contained in:
Jean-Romain Garnier 2021-08-06 16:40:22 +02:00
parent 46c8cbb182
commit dfc58a281e

View file

@ -61,8 +61,8 @@ class Deposit(RevMixin, AclMixin, models.Model):
def __init__(self, *args, **kwargs):
super(Deposit, self).__init__(*args, **kwargs)
self.__original_item = self.item
self.__original_deposit_amount = self.deposit_amount
self.__original_item = getattr(self, "item", None)
self.__original_deposit_amount = getattr(self, "deposit_amount", None)
def __str__(self):
if self.returned: