rubyforgood / growhaus_sign_in

Growhaus Sign in
3 stars 2 forks source link

Localize model names #56

Open brkane opened 9 years ago

brkane commented 9 years ago

Right now pulling model names for activity but they are all in english right now

brkane commented 9 years ago

https://github.com/globalize/globalize

bjmllr commented 9 years ago

Depending on where t is visible, we could do something like ...

before

class User
  def role_name
    role && role.name
  end
end

after

class User
  def role_name
    role && t("role.#{role.name.downcase}")
  end
end