whoopsie
This commit is contained in:
parent
c6d4c1edc3
commit
3a02cb0035
|
@ -25,6 +25,12 @@ class Order(CreatedUpdatedModel):
|
|||
through='shop.OrderProductRelation'
|
||||
)
|
||||
|
||||
user = models.ForeignKey(
|
||||
'auth.User',
|
||||
verbose_name=_('User'),
|
||||
help_text=_('The user this order belongs to.'),
|
||||
related_name='orders',
|
||||
)
|
||||
|
||||
paid = models.BooleanField(
|
||||
verbose_name=_('Paid?'),
|
||||
|
@ -259,7 +265,7 @@ class EpayPayment(CreatedUpdatedModel, UUIDModel):
|
|||
|
||||
|
||||
class CreditNote(CreatedUpdatedModel):
|
||||
amount = models.DecimalField()
|
||||
amount = models.DecimalField(max_digits=10, decimal_places=2)
|
||||
text = models.TextField()
|
||||
pdf = models.FileField(
|
||||
null=True,
|
||||
|
@ -295,6 +301,7 @@ class CreditNote(CreatedUpdatedModel):
|
|||
def filename(self):
|
||||
return 'bornhack_creditnote_%s.pdf' % self.pk
|
||||
|
||||
|
||||
class Invoice(CreatedUpdatedModel):
|
||||
order = models.OneToOneField('shop.Order')
|
||||
pdf = models.FileField(null=True, blank=True, upload_to='invoices/')
|
||||
|
|
Loading…
Reference in a new issue