Add budget investment translations to dev_seeds

Update budget investments development seeds with translations for all avaialble locales.
This commit is contained in:
Senén Rodero Rodríguez
2019-01-24 17:02:08 +01:00
committed by voodoorai2000
parent f116477d6d
commit 522b1c9ef7

View File

@@ -138,6 +138,14 @@ section "Creating Investments" do
terms_of_service: "1"
)
random_locales.map do |locale|
Globalize.with_locale(locale) do
investment.title = "Title for locale #{locale}"
investment.description = "<p>Description for locale #{locale}</p>"
investment.save!
end
end
add_image_to(investment) if Random.rand > 0.5
end
end