Preferences & email
Language, theme and notifications
Language and theme are account preferences stored in Frappe. Browser local storage is not authoritative, so the values follow the user across devices and drive email rendering.
Preference flow
Portal may apply a temporary theme instantly, but after authentication the Frappe value wins. The endpoint only permits supported values and only changes the current user.
Email selection
Core determines recipient language from the Frappe User language. Email helpers select German or English content and wrap it in the shared white Mivama layout with logo. This applies to welcome, invoice, hosting, migration and support notifications.
Templates belong in Mivama Core because Frappe schedules and sends mail. The Desk workspace exposes records and a safe preview without sending.
Preference categories
- Essential: account, security, invoice, hosting and migration messages required to operate the service.
- Service updates: operational information that can be configurable when not essential.
- Marketing: requires separate lawful basis and unsubscribe behavior.
Core checks preferences before queueing optional mail. Relevant sources are ProfileSettingsContent.tsx, portal i18n, _portal_preferences.py, _portal_email_preferences.py, email_layout.py and email_events.py.