diff --git a/assets/controllers/user_controller.js b/assets/controllers/user_controller.js index 4a71920..25ce4bf 100644 --- a/assets/controllers/user_controller.js +++ b/assets/controllers/user_controller.js @@ -1030,6 +1030,8 @@ export default class extends base_controller { event.preventDefault(); const form = event.currentTarget; const formData = new FormData(form); + const ucSurname = formData.get('surname').toUpperCase(); + formData.set('surname', ucSurname); try { const response = await fetch('/user/new/ajax', { // Adjust path if prefix is different diff --git a/src/Service/UserService.php b/src/Service/UserService.php index dbe6e6b..efd96b6 100644 --- a/src/Service/UserService.php +++ b/src/Service/UserService.php @@ -563,7 +563,7 @@ class UserService { // capitalize name and surname $user->setName(ucfirst(strtolower($user->getName()))); - $user->setSurname(ucfirst(strtolower($user->getSurname()))); + $user->setSurname(strtoupper($user->getSurname())); // trim strings $user->setName(trim($user->getName())); diff --git a/templates/organization/show.html.twig b/templates/organization/show.html.twig index a54ce55..450190f 100644 --- a/templates/organization/show.html.twig +++ b/templates/organization/show.html.twig @@ -95,7 +95,7 @@
- +