OpenEnergyDashboard / OED

Open Energy Dashboard (OED)
Mozilla Public License 2.0
73 stars 252 forks source link

don't allow cumulative reset without cumulative on meter #1209

Closed huss closed 1 month ago

huss commented 2 months ago

Is your feature request related to a problem? Please describe.

The meter edit and create pages allow the admin to select cumulative reset without also choosing cumulative. This should not be allowed to avoid mistakes.

Describe the solution you'd like

Either don't allow checking the cumulative reset if cumulative is not checked or determine after clicked, warn the admin and unselect.

Describe alternatives you've considered

Leave as is

Additional context

One example of how this is done is in the group create page where the default graphic unit is set to no unit if the selected child meter/group is not compatible with it.

mikedivine commented 1 month ago

I'll work on this issue.