|
@@ -3,6 +3,7 @@ from __future__ import unicode_literals
|
|
|
|
|
|
import datetime
|
|
|
|
|
|
+from django.conf import settings
|
|
|
from django.db import models
|
|
|
from django.db.models import Q
|
|
|
from django.core.validators import MinValueValidator
|
|
@@ -106,6 +107,9 @@ class OfferSubscription(models.Model):
|
|
|
member = models.ForeignKey('members.Member', verbose_name='membre')
|
|
|
offer = models.ForeignKey('Offer', verbose_name='offre')
|
|
|
|
|
|
+ def display_subsciption_reference(self):
|
|
|
+ return settings.SUBSCRIPTION_REFERENCE.format(subsciption=self)
|
|
|
+
|
|
|
def __unicode__(self):
|
|
|
return '%s - %s - %s' % (self.member, self.offer.name,
|
|
|
self.subscription_date)
|