SHARE
TWEET

Untitled

a guest Jun 18th, 2019 49 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. from django.contrib.auth.models import User
  2. from django.db import models
  3.  
  4.  
  5. class Profile(models.Model):
  6.     user = models.OneToOneField(User, on_delete=models.CASCADE)
  7.     phone_number = models.CharField(max_length=20)
  8.     address = models.CharField(max_length=50)
  9.      
  10. class User(AbstractBaseUser, PermissionsMixin):
  11.     email = models.EmailField(_('email address'), unique=True)
  12.     first_name = models.CharField(_('first name'), max_length=30, blank=True)
  13.     last_name = models.CharField(_('last name'), max_length=30, blank=True)
  14.     date_joined = models.DateTimeField(_('date joined'), auto_now_add=True)
  15.     is_active = models.BooleanField(_('active'), default=True)
  16.     ...
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top