models.py 520 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
from django.db import models
from django.conf import settings
from django.utils.translation import ugettext_lazy as _


class Membership(models.Model):
    """This class describes membership data"""

    user = models.ForeignKey(
        settings.AUTH_USER_MODEL,
        on_delete=models.CASCADE,
    )

    membership_type = models.CharField(
        max_length=40,
        choices=(('benefactor', _('Benefactor')),
                 ('member', _('Member')),
                 ('honorary', _('Honorary Member'))),
    )