Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from django.db import models
- CHOICE1 = (
- ('NO', 'Novice'),
- )
- CHOICE2 = (
- ('ME', 'Member'),
- )
- # Create your models here.
- class Member(models.Model):
- name = models.CharField(max_length=255)
- def __unicode__(self):
- return self.name
- foobar = models.CharField(max_length=2, choices=CHOICE1)
- barfoo = models.CharField(max_length=2, choices=CHOICE2)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement