diff --git a/app/vmui/packages/vmui/src/components/Configurators/GlobalSettings/GlobalSettings.tsx b/app/vmui/packages/vmui/src/components/Configurators/GlobalSettings/GlobalSettings.tsx index 420a048bee..4e3f60cbd3 100644 --- a/app/vmui/packages/vmui/src/components/Configurators/GlobalSettings/GlobalSettings.tsx +++ b/app/vmui/packages/vmui/src/components/Configurators/GlobalSettings/GlobalSettings.tsx @@ -16,6 +16,7 @@ import { useTimeDispatch, useTimeState } from "../../../state/time/TimeStateCont import ThemeControl from "../ThemeControl/ThemeControl"; import useDeviceDetect from "../../../hooks/useDeviceDetect"; import useBoolean from "../../../hooks/useBoolean"; +import { getTenantIdFromUrl } from "../../../utils/tenants"; const title = "Settings"; @@ -57,6 +58,10 @@ const GlobalSettings: FC = () => { }; const handlerApply = () => { + const tenantIdFromUrl = getTenantIdFromUrl(serverUrl); + if (tenantIdFromUrl !== "") { + dispatch({ type: "SET_TENANT_ID", payload: tenantIdFromUrl }); + } dispatch({ type: "SET_SERVER", payload: serverUrl }); timeDispatch({ type: "SET_TIMEZONE", payload: timezone }); customPanelDispatch({ type: "SET_SERIES_LIMITS", payload: limits }); diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 86c991f9a1..aff0ba28f4 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -30,7 +30,7 @@ The following tip changes can be tested by building VictoriaMetrics components f * BUGFIX: [vmalert](https://docs.victoriametrics.com/vmalert.html): Properly set datasource query params. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4340). Thanks to @gsakun for [the pull request](https://github.com/VictoriaMetrics/VictoriaMetrics/pull/4341). * BUGFIX: [vmauth](https://docs.victoriametrics.com/vmauth.html): Properly handle LOCAL command for proxy protocol. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/3335#issuecomment-1569864108). * BUGFIX: [vmbackupmanager](https://docs.victoriametrics.com/vmbackupmanager.html): Fixes crash on startup. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4378). - +* BUGFIX: [vmui](https://docs.victoriametrics.com/#vmui): fix bug with custom URL in global settings not respecting tenantID change. See [this issue](https://github.com/VictoriaMetrics/VictoriaMetrics/issues/4322). ## [v1.91.0](https://github.com/VictoriaMetrics/VictoriaMetrics/releases/tag/v1.91.0)