Radio frequencies (24 GHz) were displaying as "2.42e4 MHz" instead of "24200.0 MHz" because Float.round/2 returns a float that Phoenix converts to scientific notation for large numbers. Changed format_sensor_value/2 to use :erlang.float_to_binary/2 with decimals: 1 option, which formats as a string and avoids scientific notation. Verified: 24200.0 now displays as "24200.0" instead of "2.42e4" Reviewed-on: graham/towerops-web#114 |
||
|---|---|---|
| .. | ||
| channels | ||
| components | ||
| controllers | ||
| graphql | ||
| helpers | ||
| live | ||
| plugs | ||
| changelog_parser.ex | ||
| endpoint.ex | ||
| gettext.ex | ||
| gettext_helpers.ex | ||
| graphql_socket.ex | ||
| permissions.ex | ||
| plug_exceptions.ex | ||
| remote_ip.ex | ||
| router.ex | ||
| scoped_resource.ex | ||
| telemetry.ex | ||
| telemetry_filter.ex | ||
| user_auth.ex | ||