Add default Body weight quantity to seeds

Introduces db/seeds/quantities.rb with a default "Body weight" quantity
(user_id nil = system default), mirroring the pattern used by seeds/units.rb.
Wires it into db/seeds.rb so it runs on db:seed.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-03-12 08:42:13 +00:00
parent 83b064ef3c
commit fd9d2b791a
2 changed files with 10 additions and 0 deletions

9
db/seeds/quantities.rb Normal file
View File

@@ -0,0 +1,9 @@
Quantity.transaction do
Quantity.defaults.delete_all
quantities = {}
quantities['Body weight'] =
Quantity.create name: 'Body weight',
description: 'body weight measurement'
end