From 7bb4f294fce99a0b7cdc376a9c17b803e96e8348 Mon Sep 17 00:00:00 2001 From: Lucas Brandstaetter <lucas@brandstaetter.tech> Date: Sat, 30 Nov 2024 13:59:02 +0100 Subject: [PATCH] Add invitation model to the translation system --- src/core/locale/de/LC_MESSAGES/django.po | 6 ++++++ src/core/locale/en/LC_MESSAGES/django.po | 6 ++++++ .../0163_alter_invitation_options.py | 20 +++++++++++++++++++ src/core/models/invitation.py | 2 ++ 4 files changed, 34 insertions(+) create mode 100644 src/core/migrations/0163_alter_invitation_options.py diff --git a/src/core/locale/de/LC_MESSAGES/django.po b/src/core/locale/de/LC_MESSAGES/django.po index 54af1d06f..c61e33aaa 100644 --- a/src/core/locale/de/LC_MESSAGES/django.po +++ b/src/core/locale/de/LC_MESSAGES/django.po @@ -1170,6 +1170,12 @@ msgstr "Team Mitglied" msgid "Habitat" msgstr "Habitatszuordnung" +msgid "Invitation__name" +msgstr "Einladung" + +msgid "Invitation__name__plural" +msgstr "Einladungen" + msgid "Invitation__comment" msgstr "Kommentar" diff --git a/src/core/locale/en/LC_MESSAGES/django.po b/src/core/locale/en/LC_MESSAGES/django.po index dedbe2fa9..8046fe5a5 100644 --- a/src/core/locale/en/LC_MESSAGES/django.po +++ b/src/core/locale/en/LC_MESSAGES/django.po @@ -1170,6 +1170,12 @@ msgstr "Team member" msgid "Habitat" msgstr "Habitat assignment" +msgid "Invitation__name" +msgstr "invitation" + +msgid "Invitation__name__plural" +msgstr "invitations" + msgid "Invitation__comment" msgstr "comment" diff --git a/src/core/migrations/0163_alter_invitation_options.py b/src/core/migrations/0163_alter_invitation_options.py new file mode 100644 index 000000000..91948ae4b --- /dev/null +++ b/src/core/migrations/0163_alter_invitation_options.py @@ -0,0 +1,20 @@ +# Generated by Django 5.1.3 on 2024-11-30 12:58 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ("core", "0162_remove_workadventure"), + ] + + operations = [ + migrations.AlterModelOptions( + name="invitation", + options={ + "verbose_name": "Invitation__name", + "verbose_name_plural": "Invitation__name__plural", + }, + ), + ] diff --git a/src/core/models/invitation.py b/src/core/models/invitation.py index 1f5e8925e..955e1823f 100644 --- a/src/core/models/invitation.py +++ b/src/core/models/invitation.py @@ -95,6 +95,8 @@ class Invitation(models.Model): models.Index(fields=['requester_type', 'requester_id'], name='requester_idx'), models.Index(fields=['requested_type', 'requested_id'], name='requested_idx'), ] + verbose_name = _('Invitation__name') + verbose_name_plural = _('Invitation__name__plural') # Make the enums available through the class InvitationType = InvitationType -- GitLab