Answer the question
In order to leave comments, you need to log in
How to fix localization?
Installed gem 'russian', set localization.
Created corresponding entries in ru.yml
ru:
activerecord:
models:
company:
one: "Компания"
two: "Компании"
other: "Компании"
<%- model_class = Company -%>
<div class="page-header">
<h1><%=t '.title', :default => model_class.model_name.human.pluralize.titleize %></h1>
</div>
Answer the question
In order to leave comments, you need to log in
To use the abbreviation '.title' you need to write in localization like this
ru:
имя_контроллера:
имя_действия:
title:
one: Компания
other: Компании
t('.title', count: 2)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question