importing django User model as DjangoUser so no-one can mistake it as our own user model (bug 539861)

This commit is contained in:
Fred Wenzel 2010-01-18 11:51:34 +01:00
Родитель f9042aca5c
Коммит 6d04900f79
2 изменённых файлов: 4 добавлений и 4 удалений

Просмотреть файл

@ -4,7 +4,7 @@ import random
import string
from django.db import models
from django.contrib.auth.models import User
from django.contrib.auth.models import User as DjangoUser
import amo
from translations.fields import TranslatedField
@ -50,7 +50,7 @@ class UserProfile(amo.ModelBase):
resetcode_expires = models.DateTimeField(default=datetime.now)
sandboxshown = models.BooleanField(default=False)
user = models.ForeignKey(User, null=True)
user = models.ForeignKey(DjangoUser, null=True)
class Meta:
db_table = 'users'

Просмотреть файл

@ -2,7 +2,7 @@ from django.db import models
import amo
from addons.models import Addon
from users.models import User
from users.models import UserProfile
from applications.models import Application
from translations.fields import TranslatedField
@ -29,7 +29,7 @@ class License(amo.ModelBase):
class VersionComment(amo.ModelBase):
"""Editor comments for version discussion threads."""
version = models.ForeignKey(Version)
user = models.ForeignKey(User)
user = models.ForeignKey(UserProfile)
reply_to = models.ForeignKey(Version, related_name="reply_to", null=True)
subject = models.CharField(max_length=1000)
comment = models.TextField()