# Path: mineid/accounts/abstract_models.py
# class AbstractUser(AbstractBaseUser):
#     first_name = models.CharField(_('first name'), max_length=30, blank=True)
#     last_name = models.CharField(_('last name'), max_length=30, blank=True)
# 
#     username = models.CharField(
#         verbose_name=_('username'), max_length=255, unique=True, blank=False)
# 
#     email = models.EmailField(
#         verbose_name='email address', max_length=255, unique=True, null=True,
#     )
# 
#     is_admin = models.BooleanField(default=False)
#     is_staff = models.BooleanField(
#         _('staff status'), default=False,
#         help_text=_(
#             'Designates whether the user can log into this admin site.'))
#     is_active = models.BooleanField(
#         _('active'), default=True,
#         help_text=_(
#             'Designates whether this user should be treated as '
#             'active. Unselect this instead of deleting accounts.'))
# 
#     date_joined = models.DateTimeField(_('date joined'), default=timezone.now)
# 
#     USERNAME_FIELD = 'username'
#     REQUIRED_FIELDS = []
# 
#     class Meta:
#         abstract = True
# 
#     @property
#     def is_staff(self):
#         "Is the user a member of staff?"
#         # Simplest possible answer: All admins are staff
#         return self.is_admin
# 
#     def get_full_name(self):
#         # The user is identified by their email address
#         return self.email
# 
#     def get_short_name(self):
#         # The user is identified by their email address
#         return self.email
# 
#     def __str__(self):              # __unicode__ on Python 2
#         return self.email
# 
#     def has_perm(self, perm, obj=None):
#         "Does the user have a specific permission?"
#         # Simplest possible answer: Yes, always
#         return True
# 
#     def has_module_perms(self, app_label):
#         "Does the user have permissions to view the app `app_label`?"
#         # Simplest possible answer: Yes, always
#         return True
# 
#     def email_user(self, subject, message, from_email=None):
#         """
#         Sends an email to this User.
#         """
#         send_mail(subject, message, from_email, [self.email])
# 
# Path: mineid/accounts/managers.py
# class UserManager(UserManager):
#     def _create_user(self, username, email, password, is_staff,
#                      **extra_fields):
#         """
#         Creates and saves a User with the given username, email and password.
#         """
#         now = timezone.now()
#         if not username:
#             raise ValueError('The given username must be set')
#         email = self.normalize_email(email)
#         user = self.model(username=username, email=email,
#                           is_staff=is_staff, is_active=True,
#                           last_login=now, date_joined=now, **extra_fields)
#         user.set_password(password)
#         user.save(using=self._db)
#         return user
# 
#     def create_user(self, username, email=None, password=None, **extra_fields):
#         return self._create_user(username, email, password, False,
#                                  **extra_fields)
# 
#     def create_superuser(self, username, password, **extra_fields):
#         return self._create_user(username, username, password, True,
#                                  **extra_fields)


from .abstract_models import AbstractUser
from .managers import UserManager


class User(AbstractUser):
    objects = UserManager()

    def get_api_dict(self, base_url):

# Path: mineid/accounts/abstract_models.py
# class AbstractUser(AbstractBaseUser):
#     first_name = models.CharField(_('first name'), max_length=30, blank=True)
#     last_name = models.CharField(_('last name'), max_length=30, blank=True)
# 
#     username = models.CharField(
#         verbose_name=_('username'), max_length=255, unique=True, blank=False)
# 
#     email = models.EmailField(
#         verbose_name='email address', max_length=255, unique=True, null=True,
#     )
# 
#     is_admin = models.BooleanField(default=False)
#     is_staff = models.BooleanField(
#         _('staff status'), default=False,
#         help_text=_(
#             'Designates whether the user can log into this admin site.'))
#     is_active = models.BooleanField(
#         _('active'), default=True,
#         help_text=_(
#             'Designates whether this user should be treated as '
#             'active. Unselect this instead of deleting accounts.'))
# 
#     date_joined = models.DateTimeField(_('date joined'), default=timezone.now)
# 
#     USERNAME_FIELD = 'username'
#     REQUIRED_FIELDS = []
# 
#     class Meta:
#         abstract = True
# 
#     @property
#     def is_staff(self):
#         "Is the user a member of staff?"
#         # Simplest possible answer: All admins are staff
#         return self.is_admin
# 
#     def get_full_name(self):
#         # The user is identified by their email address
#         return self.email
# 
#     def get_short_name(self):
#         # The user is identified by their email address
#         return self.email
# 
#     def __str__(self):              # __unicode__ on Python 2
#         return self.email
# 
#     def has_perm(self, perm, obj=None):
#         "Does the user have a specific permission?"
#         # Simplest possible answer: Yes, always
#         return True
# 
#     def has_module_perms(self, app_label):
#         "Does the user have permissions to view the app `app_label`?"
#         # Simplest possible answer: Yes, always
#         return True
# 
#     def email_user(self, subject, message, from_email=None):
#         """
#         Sends an email to this User.
#         """
#         send_mail(subject, message, from_email, [self.email])
# 
# Path: mineid/accounts/managers.py
# class UserManager(UserManager):
#     def _create_user(self, username, email, password, is_staff,
#                      **extra_fields):
#         """
#         Creates and saves a User with the given username, email and password.
#         """
#         now = timezone.now()
#         if not username:
#             raise ValueError('The given username must be set')
#         email = self.normalize_email(email)
#         user = self.model(username=username, email=email,
#                           is_staff=is_staff, is_active=True,
#                           last_login=now, date_joined=now, **extra_fields)
#         user.set_password(password)
#         user.save(using=self._db)
#         return user
# 
#     def create_user(self, username, email=None, password=None, **extra_fields):
#         return self._create_user(username, email, password, False,
#                                  **extra_fields)
# 
#     def create_superuser(self, username, password, **extra_fields):
#         return self._create_user(username, username, password, True,
#                                  **extra_fields)


# Path: mineid/accounts/models.py
from .abstract_models import AbstractUser
from .managers import UserManager



class User(AbstractUser):
    objects = UserManager()

    def get_api_dict(self, base_url):

        data = {}