Pierre-Gilles had the idea of automatically converting the units of numeric features such as Duration, Rate or Distance.
Thus, if I have a Duration in seconds, it would display:
35s
99s => 01m39s
3900s => 01h05m00s
We could add a checkbox in the feature configuration to enable or disable this mode.
Or even a MultiComboBox to select the usable units, e.g.:
I check minutes, hours and days but not weeks, months and years.
Thus my seconds will never be converted into months.
864000s would not display « 1 week and 3 days and 00h00m00s » but « 240h00m00s ».
I wonder whether it wouldn’t be better to force all devices to use the smallest unit (e.g., nm instead of mm or cm or m or km) and do a graphical conversion based on the value… but if we want to do that, it’s a big undertaking!
Well, the problem is that if a device sends seconds, you need to know that to multiply it by 1000…
It seems more than complicated and it forces doing a lot of calculations in all directions when sending data to Gladys if we’re talking in minutes and hours.
And it would force using units that we don’t necessarily want…
I don’t think the « Unit convertible to » is necessary, we just do it sensibly and display each unit neatly (1500 Wh becomes 1.5kWh, etc.), the user has nothing to do.
[quote=« AlexTrovato, post:2, topic:8213 »]
I wonder in this case whether it wouldn’t be better to force all devices to