Add per-user language preference with company default fallback

Existing accounts inherited the company language at creation time and there was no way to change UI language per user. Add a 'Default (Company Language)' entry to the language selector in UserGeneralView, persist the choice through userStore.updateUserSettings and reload the i18n bundle via window.loadLanguage. The 'default' sentinel keeps the user opted in to the company-wide setting.

Bootstrap (global.store) now syncs userForm from current_user data and resolves the active UI language as user > company > 'en'. RegisterController, InvitationRegistrationController and MemberService seed new users with language=default instead of copying the current company setting, so promoting/inviting members no longer leaks the inviter's frozen language.
This commit is contained in:
Darko Gjorgjijoski
2026-04-07 04:41:00 +02:00
parent c5c9677ffc
commit 78ed332d06
7 changed files with 63 additions and 10 deletions

View File

@@ -73,6 +73,8 @@ class InvitationRegistrationController extends Controller
'password' => $request->password,
]);
$user->setSettings(['language' => 'default']);
$this->invitationService->accept($invitation, $user);
return response()->json([