Change Unit.multiplier type from decimal to float

Remove remnants related to BigDecimal.
This commit is contained in:
2026-07-12 17:16:43 +02:00
parent 1ab925f6fa
commit b05523dcd6
17 changed files with 134 additions and 75 deletions

View File

@@ -4,7 +4,7 @@ Unit.transaction do
<% Unit.defaults.ordered.each do |unit| %>
<%= "\n" if unit.base.nil? %>
units['<%= unit.symbol %>'] =
Unit.create symbol: '<%= unit.symbol %>',<% unless unit.base.nil? %> base: units['<%= unit.base.symbol %>'], multiplier: '<%= unit.multiplier.to_scientific %>',<% end %>
Unit.create symbol: '<%= unit.symbol %>',<% if unit.base_id? %> base: units['<%= unit.base.symbol %>'], multiplier: '<%= unit.multiplier.to_scientific %>',<% end %>
description: '<%= unit.description %>'
<% end %>
end