From 2b5a9e1af8b00c58d49e27102c930c734fe993b8 Mon Sep 17 00:00:00 2001 From: Manuel Raynaud Date: Wed, 22 Oct 2025 11:44:39 +0200 Subject: [PATCH] =?UTF-8?q?=E2=99=BB=EF=B8=8F(backend)=20increase=20user?= =?UTF-8?q?=20short=5Fname=20field=20length?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The user's short_name field length was set to 20. This is not enought and we have some users who cannot register because of that. We changed this length to a higher one, 100, like the full_name. --- CHANGELOG.md | 6 +++++- .../migrations/0025_alter_user_short_name.py | 19 +++++++++++++++++++ src/backend/core/models.py | 4 +++- 3 files changed, 27 insertions(+), 2 deletions(-) create mode 100644 src/backend/core/migrations/0025_alter_user_short_name.py diff --git a/CHANGELOG.md b/CHANGELOG.md index 812679ee..b4f85614 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,11 @@ and this project adheres to ## [Unreleased] -## Fixed +### Changed + +- ♻️(backend) increase user short_name field length + +### Fixed - 🐛(frontend) fix duplicate document entries in grid #1479 - 🐛(frontend) show full nested doc names with ajustable bar #1456 diff --git a/src/backend/core/migrations/0025_alter_user_short_name.py b/src/backend/core/migrations/0025_alter_user_short_name.py new file mode 100644 index 00000000..3ffc3116 --- /dev/null +++ b/src/backend/core/migrations/0025_alter_user_short_name.py @@ -0,0 +1,19 @@ +# Generated by Django 5.2.7 on 2025-10-22 06:12 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + dependencies = [ + ("core", "0024_add_is_masked_field_to_link_trace"), + ] + + operations = [ + migrations.AlterField( + model_name="user", + name="short_name", + field=models.CharField( + blank=True, max_length=100, null=True, verbose_name="short name" + ), + ), + ] diff --git a/src/backend/core/models.py b/src/backend/core/models.py index 941c72ec..6e0ad69e 100644 --- a/src/backend/core/models.py +++ b/src/backend/core/models.py @@ -148,7 +148,9 @@ class User(AbstractBaseUser, BaseModel, auth_models.PermissionsMixin): ) full_name = models.CharField(_("full name"), max_length=100, null=True, blank=True) - short_name = models.CharField(_("short name"), max_length=20, null=True, blank=True) + short_name = models.CharField( + _("short name"), max_length=100, null=True, blank=True + ) email = models.EmailField(_("identity email address"), blank=True, null=True)