1
0
mirror of https://github.com/django/django.git synced 2025-07-04 09:49:12 +00:00

magic-removal: Fixed #1670 -- Added translation hooks for User and Group model fields that didn't have them.

git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@2727 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Adrian Holovaty 2006-04-23 21:16:26 +00:00
parent 43395b0993
commit e55924b833

View File

@ -24,7 +24,7 @@ class Permission(models.Model):
class Group(models.Model): class Group(models.Model):
name = models.CharField(_('name'), maxlength=80, unique=True) name = models.CharField(_('name'), maxlength=80, unique=True)
permissions = models.ManyToManyField(Permission, blank=True, filter_interface=models.HORIZONTAL) permissions = models.ManyToManyField(_('permissions'), Permission, blank=True, filter_interface=models.HORIZONTAL)
class Meta: class Meta:
verbose_name = _('Group') verbose_name = _('Group')
verbose_name_plural = _('Groups') verbose_name_plural = _('Groups')
@ -62,9 +62,9 @@ class User(models.Model):
is_superuser = models.BooleanField(_('superuser status')) is_superuser = models.BooleanField(_('superuser status'))
last_login = models.DateTimeField(_('last login'), default=models.LazyDate()) last_login = models.DateTimeField(_('last login'), default=models.LazyDate())
date_joined = models.DateTimeField(_('date joined'), default=models.LazyDate()) date_joined = models.DateTimeField(_('date joined'), default=models.LazyDate())
groups = models.ManyToManyField(Group, blank=True, groups = models.ManyToManyField(_('groups'), Group, blank=True,
help_text=_("In addition to the permissions manually assigned, this user will also get all permissions granted to each group he/she is in.")) help_text=_("In addition to the permissions manually assigned, this user will also get all permissions granted to each group he/she is in."))
user_permissions = models.ManyToManyField(Permission, blank=True, filter_interface=models.HORIZONTAL) user_permissions = models.ManyToManyField(_('user permissions'), Permission, blank=True, filter_interface=models.HORIZONTAL)
objects = UserManager() objects = UserManager()
class Meta: class Meta:
verbose_name = _('User') verbose_name = _('User')