Skip to content

Commit be94cd6

Browse files
committed
Implemented Verbose Name Translation for TokenProxy
1 parent 35c5be6 commit be94cd6

File tree

2 files changed

+19
-1
lines changed

2 files changed

+19
-1
lines changed
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# Generated by Django 4.1.3 on 2022-11-24 21:07
2+
3+
from django.db import migrations
4+
5+
6+
class Migration(migrations.Migration):
7+
8+
dependencies = [
9+
('authtoken', '0003_tokenproxy'),
10+
]
11+
12+
operations = [
13+
migrations.AlterModelOptions(
14+
name='tokenproxy',
15+
options={'verbose_name': 'Token', 'verbose_name_plural': 'Tokens'},
16+
),
17+
]

rest_framework/authtoken/models.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,4 +51,5 @@ def pk(self):
5151
class Meta:
5252
proxy = 'rest_framework.authtoken' in settings.INSTALLED_APPS
5353
abstract = 'rest_framework.authtoken' not in settings.INSTALLED_APPS
54-
verbose_name = "token"
54+
verbose_name = _("Token")
55+
verbose_name_plural = _("Tokens")

0 commit comments

Comments
 (0)