Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
D
django
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
django
Commits
c6280796
Kaydet (Commit)
c6280796
authored
Şub 23, 2016
tarafından
Tim Graham
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fixed a stray __unicode__() method in auth_tests.
üst
e81d1c99
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
1 deletion
+3
-1
custom_user.py
tests/auth_tests/models/custom_user.py
+3
-1
No files found.
tests/auth_tests/models/custom_user.py
Dosyayı görüntüle @
c6280796
...
...
@@ -3,6 +3,7 @@ from django.contrib.auth.models import (
PermissionsMixin
,
UserManager
,
)
from
django.db
import
models
from
django.utils.encoding
import
python_2_unicode_compatible
# The custom User uses email as the unique identifier, and requires
...
...
@@ -32,6 +33,7 @@ class CustomUserManager(BaseUserManager):
return
u
@python_2_unicode_compatible
class
CustomUser
(
AbstractBaseUser
):
email
=
models
.
EmailField
(
verbose_name
=
'email address'
,
max_length
=
255
,
unique
=
True
)
is_active
=
models
.
BooleanField
(
default
=
True
)
...
...
@@ -49,7 +51,7 @@ class CustomUser(AbstractBaseUser):
def
get_short_name
(
self
):
return
self
.
email
def
__
unicode
__
(
self
):
def
__
str
__
(
self
):
return
self
.
email
# Maybe required?
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment