dawarich icon indicating copy to clipboard operation
dawarich copied to clipboard

Changed Layer settings are reset to the default upon the map refresh

Open skv25 opened this issue 7 months ago • 1 comments

OS & Hardware CentOS Linux release 7.9.2009, Docker version 26.1.4, build 5650f9b

Version 0.25.8

Describe the bug In the map view, if change the default Layer settings (e.g. enable Points), the settings are not retained and reset to the default when the map is refreshed.

To Reproduce Steps to reproduce the behavior:

  1. Go to the Map view (http://dawarich.local/map)
  2. Click the Layers button, observe the default settings: Enabled by default are Routes, Heatmap and Confirmed Visits
  3. Change any of the settings, e.g. enable Points and disable Heatmap
  4. Refresh the map by refreshing the page in the browser, or clicking the logo in top-left corner, or clicking Search
  5. The Layer settings are reset to the defaults listed in Step 2.

Expected behavior The Layer settings are saved and kept until the user changes them.

Screenshots Easy to repro but let me know if you'd like me to record the screen to illustrate the behavior.

Logs Doesn't seem to be applicable

Additional context None

skv25 avatar Apr 29 '25 07:04 skv25

Please provide logs from dawarich_app container

Freika avatar Apr 29 '25 18:04 Freika

Please provide logs from dawarich_app container

There is nothing to log, this is entirely frontend. There are no network requests made at all.

It's very easy to reproduce:

  • Open dawarich
  • Open devtools network tab
  • From map layers, enable "points" and disable "heatmap"
  • Notice no requests sent to the backend
  • Refresh the page
  • Notice "points" are disabled and "heatmap" is enabled again

Layers selection should be stored in the backend (ideally) or at least in local storage on the frontend.

dcelasun avatar Jun 10 '25 14:06 dcelasun

Ah, misunderstood.

Not preserving layers state (enabled points, disabled heatmap, for example) is the intended behavior. It might be changed in the future.

Freika avatar Jun 10 '25 18:06 Freika

OK, thanks. Opened a feature request discussion: https://github.com/Freika/dawarich/discussions/1402

dcelasun avatar Jun 10 '25 18:06 dcelasun