fix(dashboard): persist the currency & timezone widgets so an upgrade keeps them (#1311)

The currency and timezone widgets stored their state only in browser localStorage, so a (docker) upgrade that clears site storage reset them to defaults — unlike every other preference, which is saved server-side. Persist them through the per-user settings store (no schema change; the settings table takes arbitrary keys) and migrate any existing localStorage values on first load so users keep their picks. dashboard_timezones is left unset by default so the widget can tell 'never chosen' from an explicitly emptied list.
This commit is contained in:
Maurice
2026-06-27 12:19:40 +02:00
committed by Maurice
parent eb0ab4001d
commit 3554fde8d6
4 changed files with 74 additions and 13 deletions
+4
View File
@@ -124,6 +124,10 @@ export interface Settings {
maplibre_style?: string
mapbox_3d_enabled?: boolean
mapbox_quality_mode?: boolean
// Dashboard widget prefs — persisted server-side so a (docker) upgrade keeps them (#1311).
dashboard_fx_from?: string
dashboard_fx_to?: string
dashboard_timezones?: string[]
}
export interface AssignmentsMap {