Skip to content
This repository has been archived by the owner on Oct 10, 2019. It is now read-only.

Commit

Permalink
fix locales
Browse files Browse the repository at this point in the history
  • Loading branch information
mikhkonkov committed Mar 16, 2017
1 parent c192cbd commit 4c39c03
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 16 deletions.
2 changes: 1 addition & 1 deletion app/views/web/admin/users/_form.html.haml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
= simple_form_for @user, url: url, html: { method: method, class: 'form-horizontal' } do |f|
= f.input :name
= f.input :email
= f.input :email, input_html: { placeholder: '[email protected]' }
= f.input :description
.form-group
.col-sm-offset-3.col-sm-9
Expand Down
5 changes: 4 additions & 1 deletion app/views/web/admin/users/index.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,15 @@

%table.table.table-hover.table-condensed.table-striped
%tr
%th Имя
%th Фамилия Имя
%th Email
%th Действия
- @users.each do |user|
%tr
%td
= user.name
%td
= user.email
%td
= link_to 'Редактировать', edit_admin_user_path(user), class: 'btn btn-info btn-sm'
= link_to 'Удалить', admin_user_path(user), method: :delete, data: { confirm: 'Вы уверены?' }, class: 'btn btn-danger btn-sm'
Expand Down
22 changes: 19 additions & 3 deletions config/locales/activerecord.ru.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,22 @@ ru:
activerecord:
attributes:
dish:
name: 'Название'
description: 'Описание'
dish_type: 'Тип блюда'
name: Название
description: Описание
dish_type: Тип блюда
user:
name: Фамилия Имя
email: Email
neem: Не есть
description: Описание

errors:
models:
user:
attributes:
email:
blank: Введите email
invalid_email: Введите Рестрим email, вида [email protected]
name:
blank: Введите Фамилию и Имя

11 changes: 0 additions & 11 deletions config/locales/ru.yml
Original file line number Diff line number Diff line change
@@ -1,15 +1,4 @@
ru:
activerecord:
errors:
models:
user:
attributes:
email:
blank: Введите email
invalid_email: Введите Рестрим email, вида [email protected]
name:
blank: Введите Фамилию и Имя

date:
formats:
menu_date: '%d %B, %A'
Expand Down

0 comments on commit 4c39c03

Please sign in to comment.