Add missing translations in admin area

#341
This commit is contained in:
Artur Beljajev 2017-01-18 08:31:28 +02:00
parent c18def3c12
commit 40459e8b2e
33 changed files with 138 additions and 95 deletions

View file

@ -32,11 +32,11 @@
%li.dropdown-header= t(:system) %li.dropdown-header= t(:system)
%li= link_to t(:settings), admin_settings_path %li= link_to t(:settings), admin_settings_path
%li= link_to t(:zonefile), admin_zonefile_settings_path %li= link_to t(:zonefile), admin_zonefile_settings_path
%li= link_to t(:blocked_domains), admin_blocked_domains_path %li= link_to t('.blocked_domains'), admin_blocked_domains_path
%li= link_to t(:reserved_domains), admin_reserved_domains_path %li= link_to t('.reserved_domains'), admin_reserved_domains_path
%li= link_to t(:mail_templates), admin_mail_templates_path %li= link_to t(:mail_templates), admin_mail_templates_path
%li= link_to t(:epp_logs), admin_epp_logs_path(created_after: 'today') %li= link_to t('.epp_log'), admin_epp_logs_path(created_after: 'today')
%li= link_to t(:repp_logs), admin_repp_logs_path(created_after: 'today') %li= link_to t('.repp_log'), admin_repp_logs_path(created_after: 'today')
%li= link_to t('.que'), '/admin/que' %li= link_to t('.que'), '/admin/que'
- if signed_in? - if signed_in?

View file

@ -38,8 +38,7 @@
   
%span.glyphicon.glyphicon-search %span.glyphicon.glyphicon-search
   
%button.btn.btn-default.js-reset-form = link_to(t('.reset_btn'), admin_account_activities_path, class: 'btn btn-default')
= t(:clear_fields)
.row .row
.col-md-3 .col-md-3
.col-md-3 .col-md-3
@ -87,8 +86,3 @@
.row .row
.col-md-12 .col-md-12
= paginate @account_activities = paginate @account_activities
:coffee
$(".js-reset-form").on "click", (e) ->
e.preventDefault();
window.location = "#{admin_account_activities_path}"

View file

@ -1,6 +1,6 @@
- content_for :actions do - content_for :actions do
= link_to(t(:create_new_user), new_admin_admin_user_path, class: 'btn btn-primary') = link_to(t('.new_btn'), new_admin_admin_user_path, class: 'btn btn-primary')
= render 'shared/title', name: t(:admin_users) = render 'shared/title', name: t('.title')
.row .row
.col-md-12 .col-md-12
@ -23,7 +23,7 @@
%td= x.email %td= x.email
%td= x.identity_code %td= x.identity_code
- if x.roles - if x.roles
%td= t(x.roles.first) %td= x.roles.first
- else - else
%td %td
.row .row

View file

@ -1,3 +1,3 @@
= render 'shared/title', name: t(:create_new_user) = render 'shared/title', name: t('.title')
= render 'form' = render 'form'

View file

@ -46,12 +46,12 @@
= f.label :role, class: 'required' = f.label :role, class: 'required'
.col-md-7 .col-md-7
= select_tag 'api_user[roles][]', = select_tag 'api_user[roles][]',
options_for_select(ApiUser::ROLES.map {|x| [t(x), x] }, @api_user.roles.try(:first)), options_for_select(ApiUser::ROLES.map {|x| [x, x] }, @api_user.roles.try(:first)),
class: 'form-control selectize' class: 'form-control selectize'
.checkbox .checkbox
%label{for: 'api_user_active'} %label{for: 'api_user_active'}
= f.check_box(:active) = f.check_box(:active)
= t(:active) = t('.active')
%hr %hr
@ -59,6 +59,8 @@
.col-md-8.text-right .col-md-8.text-right
= button_tag(t(:save), class: 'btn btn-primary') = button_tag(t(:save), class: 'btn btn-primary')
:coffee :javascript
Autocomplete.bindAdminRegistrarSearch() window.addEventListener('load', function() {
$("#api_user_password").removeAttr('required') Autocomplete.bindAdminRegistrarSearch();
$("#api_user_password").removeAttr('required');
});

View file

@ -1,6 +1,6 @@
- content_for :actions do - content_for :actions do
= link_to(t(:create_new_api_user), new_admin_api_user_path, class: 'btn btn-primary') = link_to(t('.new_btn'), new_admin_api_user_path, class: 'btn btn-primary')
= render 'shared/title', name: t(:api_users) = render 'shared/title', name: t('.title')
.row .row
.col-md-12 .col-md-12
@ -13,7 +13,7 @@
%th{class: 'col-xs-2'} %th{class: 'col-xs-2'}
= sort_link(@q, 'registrar_name', t(:registrar_name)) = sort_link(@q, 'registrar_name', t(:registrar_name))
%th{class: 'col-xs-2'} %th{class: 'col-xs-2'}
= sort_link(@q, 'active', t(:active)) = sort_link(@q, 'active', t('.active'))
%tbody %tbody
- @api_users.each do |x| - @api_users.each do |x|
%tr %tr

View file

@ -1,3 +1,3 @@
= render 'shared/title', name: t(:create_new_api_user) = render 'shared/title', name: t('.title')
= render 'form' = render 'form'

View file

@ -1,6 +1,6 @@
- content_for :actions do - content_for :actions do
= link_to(t(:new), new_admin_blocked_domain_path, class: 'btn btn-primary') = link_to(t('.new_btn'), new_admin_blocked_domain_path, class: 'btn btn-primary')
= render 'shared/title', name: t(:blocked_domains) = render 'shared/title', name: t('.title')
.row .row
.col-md-12 .col-md-12
@ -28,8 +28,7 @@
   
%span.glyphicon.glyphicon-search %span.glyphicon.glyphicon-search
   
%button.btn.btn-default.js-reset-form = link_to(t('.reset_btn'), admin_blocked_domains_path, class: 'btn btn-default')
= t(:clear_fields)
%hr %hr
.row .row
.col-md-12 .col-md-12
@ -61,8 +60,3 @@
.col-md-6.text-right .col-md-6.text-right
.pagination .pagination
= t(:result_count, count: @domains.total_count) = t(:result_count, count: @domains.total_count)
:coffee
$(".js-reset-form").on "click", (e) ->
e.preventDefault();
window.location = "#{admin_blocked_domains_path}"

View file

@ -32,8 +32,7 @@
   
%span.glyphicon.glyphicon-search %span.glyphicon.glyphicon-search
   
%button.btn.btn-default.js-reset-form = link_to(t('.reset_btn'), admin_contact_versions_path, class: 'btn btn-default')
= t(:clear_fields)
%hr %hr
@ -78,9 +77,3 @@
.col-md-6.text-right .col-md-6.text-right
.pagination .pagination
= t(:result_count, count: @versions.total_count) = t(:result_count, count: @versions.total_count)
:coffee
$(".js-reset-form").on "click", (e) ->
e.preventDefault();
window.location = "#{admin_contact_versions_path}"

View file

@ -1,6 +1,6 @@
- content_for :actions do - content_for :actions do
= link_to(t(:add_new_status), '#', class: 'btn btn-primary js-add-status') = link_to(t('.new_status_btn'), '#', class: 'btn btn-primary js-add-status')
= link_to(t(:back_to_contact), [:admin, @contact], class: 'btn btn-default') = link_to(t('.back_btn'), [:admin, @contact], class: 'btn btn-default')
= render 'shared/title', name: "#{t(:edit)}: #{@contact.name}" = render 'shared/title', name: "#{t(:edit)}: #{@contact.name}"
= render 'form', contact: @contact = render 'form', contact: @contact

View file

@ -18,7 +18,7 @@
%th{class: 'col-xs-3'}=custom_sort_link t(:domain_name), :name %th{class: 'col-xs-3'}=custom_sort_link t(:domain_name), :name
%th{class: 'col-xs-3'}=custom_sort_link t(:registrar_name), :registrar_name %th{class: 'col-xs-3'}=custom_sort_link t(:registrar_name), :registrar_name
%th{class: 'col-xs-3'}=custom_sort_link t(:valid_to), :valid_to %th{class: 'col-xs-3'}=custom_sort_link t(:valid_to), :valid_to
%th{class: 'col-xs-3'}= t(:roles) %th{class: 'col-xs-3'}= t('.roles')
%tbody %tbody
- domains.each do |x| - domains.each do |x|
%tr %tr

View file

@ -27,13 +27,13 @@
%br %br
%dt= t(:created) %dt= t('.created')
%dd %dd
= l(@contact.created_at, format: :short) = l(@contact.created_at, format: :short)
by by
= creator_link(@contact) = creator_link(@contact)
%dt= t(:updated) %dt= t('.updated')
%dd %dd
= l(@contact.updated_at, format: :short) = l(@contact.updated_at, format: :short)
by by

View file

@ -32,8 +32,7 @@
   
%span.glyphicon.glyphicon-search %span.glyphicon.glyphicon-search
   
%button.btn.btn-default.js-reset-form = link_to(t('.reset_btn'), admin_domain_versions_path, class: 'btn btn-default')
= t(:clear_fields)
%hr %hr
@ -84,9 +83,3 @@
.col-md-6.text-right .col-md-6.text-right
.pagination .pagination
= t(:result_count, count: @versions.total_count) = t(:result_count, count: @versions.total_count)
:coffee
$(".js-reset-form").on "click", (e) ->
e.preventDefault();
window.location = "#{admin_domain_versions_path}"

View file

@ -47,7 +47,7 @@
   
%span.glyphicon.glyphicon-search %span.glyphicon.glyphicon-search
   
= link_to(t(:clear_fields), admin_domains_path, class: 'btn btn-default') = link_to(t('.reset_btn'), admin_domains_path, class: 'btn btn-default')
%hr %hr
.row .row
.col-md-12 .col-md-12

View file

@ -22,11 +22,11 @@
%dt= t(:valid_to) %dt= t(:valid_to)
%dd= l(@domain.valid_to) %dd= l(@domain.valid_to)
%dt= t(:outzone_at) %dt= t('.outzone_time')
%dd= l(@domain.outzone_at) %dd= l(@domain.outzone_at)
%dt= t(:delete_at) %dt= t('.delete_time')
%dd= l(@domain.delete_at) %dd= l(@domain.delete_at)
%dt= t(:force_delete_at) %dt= t('.force_delete_time')
%dd= l(@domain.force_delete_at) %dd= l(@domain.force_delete_at)

View file

@ -1,4 +1,4 @@
= render 'shared/title', name: t(:epp_logs) = render 'shared/title', name: t('.title')
.row .row
.col-md-12 .col-md-12
@ -41,8 +41,7 @@
   
%span.glyphicon.glyphicon-search %span.glyphicon.glyphicon-search
   
%button.btn.btn-default.js-reset-form = link_to(t('.reset_btn'), admin_epp_logs_path, class: 'btn btn-default')
= t(:clear_fields)
.row .row
.col-md-12 .col-md-12
%hr %hr
@ -70,8 +69,3 @@
.row .row
.col-md-12 .col-md-12
= paginate @epp_logs = paginate @epp_logs
:coffee
$(".js-reset-form").on "click", (e) ->
e.preventDefault();
window.location = "#{admin_epp_logs_path}"

View file

@ -68,16 +68,16 @@
#epp-users.panel.panel-default #epp-users.panel.panel-default
.panel-heading.clearfix .panel-heading.clearfix
.pull-left .pull-left
= t(:api_users) = t('.api_users')
.pull-right .pull-right
= link_to(t(:create_new_api_user), new_admin_registrar_api_user_path(@registrar), class: 'btn btn-default btn-xs') = link_to(t('.new_api_use_btn'), new_admin_registrar_api_user_path(@registrar), class: 'btn btn-default btn-xs')
.table-responsive .table-responsive
%table.table.table-hover.table-bordered.table-condensed %table.table.table-hover.table-bordered.table-condensed
%thead %thead
%tr %tr
%th{class: 'col-xs-6'}= t(:username) %th{class: 'col-xs-6'}= t(:username)
%th{class: 'col-xs-6'}= t(:active) %th{class: 'col-xs-6'}= t('.active')
%tbody %tbody
- @registrar.api_users.each do |x| - @registrar.api_users.each do |x|
%tr %tr

View file

@ -1,4 +1,4 @@
= render 'shared/title', name: t(:repp_logs) = render 'shared/title', name: t('.title')
.row .row
.col-md-12 .col-md-12
@ -39,8 +39,7 @@
   
%span.glyphicon.glyphicon-search %span.glyphicon.glyphicon-search
   
%button.btn.btn-default.js-reset-form = link_to(t('.reset_btn'), admin_repp_logs_path, class: 'btn btn-default')
= t(:clear_fields)
%hr %hr
.row .row
.col-md-12 .col-md-12
@ -67,8 +66,3 @@
.row .row
.col-md-12 .col-md-12
= paginate @repp_logs = paginate @repp_logs
:coffee
$(".js-reset-form").on "click", (e) ->
e.preventDefault();
window.location = "#{admin_repp_logs_path}"

View file

@ -1,6 +1,6 @@
- content_for :actions do - content_for :actions do
= link_to(t(:new), new_admin_reserved_domain_path, class: 'btn btn-primary') = link_to(t('.new_btn'), new_admin_reserved_domain_path, class: 'btn btn-primary')
= render 'shared/title', name: t(:reserved_domains) = render 'shared/title', name: t('.title')
.row .row
.col-md-12 .col-md-12
@ -28,8 +28,7 @@
   
%span.glyphicon.glyphicon-search %span.glyphicon.glyphicon-search
   
%button.btn.btn-default.js-reset-form = link_to(t('.reset_btn'), admin_reserved_domains_path, class: 'btn btn-default')
= t(:clear_fields)
%hr %hr
.row .row
.col-md-12 .col-md-12
@ -65,8 +64,3 @@
.col-md-6.text-right .col-md-6.text-right
.pagination .pagination
= t(:result_count, count: @domains.total_count) = t(:result_count, count: @domains.total_count)
:coffee
$(".js-reset-form").on "click", (e) ->
e.preventDefault();
window.location = "#{admin_reserved_domains_path}"

View file

@ -0,0 +1,5 @@
en:
admin:
account_activities:
index:
reset_btn: Reset

View file

@ -0,0 +1,8 @@
en:
admin:
admin_users:
index:
title: Admin users
new_btn: New admin user
new:
title: New admin user

View file

@ -0,0 +1,13 @@
en:
admin:
api_users:
index:
new_btn: New API user
title: API users
active: Active
new:
title: New API user
form:
active: Active

View file

@ -0,0 +1,7 @@
en:
admin:
blocked_domains:
index:
title: Blocked domains
new_btn: New blocked domain
reset_btn: Reset

View file

@ -0,0 +1,5 @@
en:
admin:
contact_versions:
index:
reset_btn: Reset

View file

@ -3,3 +3,15 @@ en:
contacts: contacts:
index: index:
reset_btn: Reset reset_btn: Reset
edit:
new_status_btn: Add new status
back_btn: Back to contact
partials:
general:
created: Created
updated: Updated
domains:
roles: Roles

View file

@ -0,0 +1,5 @@
en:
admin:
domain_versions:
archive:
reset_btn: Reset

View file

@ -1,6 +1,15 @@
en: en:
admin: admin:
domains: domains:
index:
reset_btn: Reset
versions: versions:
time: Time time: Time
admin_contact: Admin contact admin_contact: Admin contact
partials:
general:
outzone_time: Outzone time
delete_time: Delete time
force_delete_time: Force delete time

View file

@ -0,0 +1,6 @@
en:
admin:
epp_logs:
index:
title: EPP log
reset_btn: Reset

View file

@ -7,4 +7,8 @@ en:
archive: Archive archive: Archive
domain_history: Domain history domain_history: Domain history
contact_history: Contact history contact_history: Contact history
blocked_domains: Blocked domains
reserved_domains: Reserved domains
epp_log: EPP log
repp_log: REPP log
que: Que que: Que

View file

@ -0,0 +1,7 @@
en:
admin:
registrars:
show:
new_api_use_btn: New API user
active: Active
api_users: API users

View file

@ -0,0 +1,6 @@
en:
admin:
repp_logs:
index:
title: REPP log
reset_btn: Reset

View file

@ -0,0 +1,7 @@
en:
admin:
reserved_domains:
index:
title: Reserved domains
new_btn: New reserved domain
reset_btn: Reset

View file

@ -407,12 +407,10 @@ en:
failed_to_delete_registrar: 'Failed to delete registrar' failed_to_delete_registrar: 'Failed to delete registrar'
users: 'Users' users: 'Users'
create_new_user: 'Create new user'
user_details: 'User details' user_details: 'User details'
edit_user: 'Edit user' edit_user: 'Edit user'
back_to_user: 'Back to user' back_to_user: 'Back to user'
create_new_api_user: 'Create new API user'
certificate_signing_req: 'Certificate signing request' certificate_signing_req: 'Certificate signing request'
csr: 'CSR' csr: 'CSR'
crt: 'CRT' crt: 'CRT'
@ -459,7 +457,6 @@ en:
zonefile_settings: 'Zonefile settings' zonefile_settings: 'Zonefile settings'
background_jobs: Background jobs background_jobs: Background jobs
domains_history: Domains history domains_history: Domains history
admin_users: Admin users
role: 'Role' role: 'Role'
user: 'User' user: 'User'
customer_service: 'Customer service' customer_service: 'Customer service'
@ -481,8 +478,6 @@ en:
action_failed_due_to_server_error: 'Action failed due to server error' action_failed_due_to_server_error: 'Action failed due to server error'
pending_transfer_was_not_found: 'Pending transfer was not found' pending_transfer_was_not_found: 'Pending transfer was not found'
transfer_can_be_rejected_only_by_current_registrar: 'Transfer can be rejected only by current registrar' transfer_can_be_rejected_only_by_current_registrar: 'Transfer can be rejected only by current registrar'
epp_logs: 'EPP logs'
epp_log: 'EPP log'
request_command: 'Request command' request_command: 'Request command'
request_object: 'Request object' request_object: 'Request object'
api_user: 'API user' api_user: 'API user'
@ -494,8 +489,6 @@ en:
request_method: 'Request method' request_method: 'Request method'
response_code: 'Response code' response_code: 'Response code'
request_params: 'Request params' request_params: 'Request params'
repp_log: 'REPP log'
repp_logs: 'REPP logs'
could_not_determine_object_type_check_xml_format_and_namespaces: 'Could not determine object type. Check XML format and namespaces.' could_not_determine_object_type_check_xml_format_and_namespaces: 'Could not determine object type. Check XML format and namespaces.'
unknown_expiry_relative_pattern: 'Expiry relative must be compatible to ISO 8601' unknown_expiry_relative_pattern: 'Expiry relative must be compatible to ISO 8601'
unknown_expiry_absolute_pattern: 'Expiry absolute must be compatible to ISO 8601' unknown_expiry_absolute_pattern: 'Expiry absolute must be compatible to ISO 8601'
@ -880,7 +873,6 @@ en:
registry_state: 'State / Province' registry_state: 'State / Province'
registry_zip: 'Postcode' registry_zip: 'Postcode'
registry_country_code: 'Country' registry_country_code: 'Country'
blocked_domains: 'Blocked domains'
billing_failure_credit_balance_low: 'Billing failure - credit balance low' billing_failure_credit_balance_low: 'Billing failure - credit balance low'
create: 'Create' create: 'Create'
activity_type: 'Activity type' activity_type: 'Activity type'
@ -888,7 +880,6 @@ en:
receipt_date_until: 'Receipt date until' receipt_date_until: 'Receipt date until'
add_credit: 'Add credit' add_credit: 'Add credit'
export_csv: 'Export CSV' export_csv: 'Export CSV'
reserved_domains: 'Reserved domains'
invalid_yaml: 'Invalid YAML' invalid_yaml: 'Invalid YAML'
reserved_pw: 'Reserved pw' reserved_pw: 'Reserved pw'
no_transfers_found: 'No transfers found' no_transfers_found: 'No transfers found'