diff options
Diffstat (limited to 'postgresqleu/adyen/models.py')
| -rw-r--r-- | postgresqleu/adyen/models.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/postgresqleu/adyen/models.py b/postgresqleu/adyen/models.py index f250f26b..d7d593e3 100644 --- a/postgresqleu/adyen/models.py +++ b/postgresqleu/adyen/models.py @@ -1,5 +1,6 @@ from django.db import models + class RawNotification(models.Model): # This class contains the raw http POSTs of all notifications received # from Adyen. They will only end up unconfirmed here if sometihng @@ -11,6 +12,7 @@ class RawNotification(models.Model): def __unicode__(self): return "%s" % self.dat + class Notification(models.Model): receivedat = models.DateTimeField(null=False, blank=False, auto_now_add=True, unique=True) rawnotification = models.ForeignKey(RawNotification, null=True, blank=True, on_delete=models.CASCADE) @@ -35,6 +37,7 @@ class Notification(models.Model): def __unicode__(self): return "%s" % self.receivedat + class Report(models.Model): receivedat = models.DateTimeField(null=False, blank=False, auto_now_add=True) notification = models.ForeignKey(Notification, null=False, blank=False, on_delete=models.CASCADE) @@ -43,6 +46,7 @@ class Report(models.Model): contents = models.TextField(null=True, blank=True) processedat = models.DateTimeField(null=True, blank=True) + class TransactionStatus(models.Model): pspReference = models.CharField(max_length=100, null=False, blank=False, unique=True) notification = models.ForeignKey(Notification, null=False, blank=False, on_delete=models.CASCADE) @@ -61,6 +65,7 @@ class TransactionStatus(models.Model): class Meta: verbose_name_plural = 'Transaction statuses' + class Refund(models.Model): receivedat = models.DateTimeField(null=False, blank=False, auto_now_add=True) notification = models.ForeignKey(Notification, null=False, blank=False, on_delete=models.CASCADE) @@ -70,6 +75,7 @@ class Refund(models.Model): def __unicode__(self): return unicode(self.refund_amount) + class ReturnAuthorizationStatus(models.Model): pspReference = models.CharField(max_length=100, null=False, blank=False, primary_key=True) seencount = models.IntegerField(null=False, default=0) |
