diff --git a/app/views/admin/base/_menu.haml b/app/views/admin/base/_menu.haml index 4037ef23e..7c813e43e 100644 --- a/app/views/admin/base/_menu.haml +++ b/app/views/admin/base/_menu.haml @@ -11,7 +11,7 @@ - if can?(:access, :settings_menu) %li.dropdown %a.dropdown-toggle{"data-toggle" => "dropdown", href: "#"} - = t(:settings) + = t('.settings') %span.caret %ul.dropdown-menu{role: "menu"} %li.dropdown-header= t('.users') @@ -30,7 +30,7 @@ %li= link_to t('.contact_history'), admin_contact_versions_path %li.divider %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('.zones'), admin_zones_path %li= link_to t('.blocked_domains'), admin_blocked_domains_path %li= link_to t('.reserved_domains'), admin_reserved_domains_path diff --git a/app/views/admin/settings/_setting_row.haml b/app/views/admin/settings/_setting_row.haml index ab0d8d991..7f11c2c63 100644 --- a/app/views/admin/settings/_setting_row.haml +++ b/app/views/admin/settings/_setting_row.haml @@ -1,6 +1,6 @@ - value = Setting.send(var) %tr{class: (@errors && @errors.has_key?(var.to_s) && "danger")} - %td= t(var) + %td= var.to_s.humanize - if [TrueClass, FalseClass].include?(value.class) %td = hidden_field_tag("[settings][#{var}]", '') diff --git a/app/views/admin/settings/index.haml b/app/views/admin/settings/index.haml index 8598fe072..d765aea6f 100644 --- a/app/views/admin/settings/index.haml +++ b/app/views/admin/settings/index.haml @@ -1,15 +1,11 @@ -= render 'shared/title', name: t(:settings) += render 'shared/title', name: t('.title') = form_tag [:admin, :settings] do .panel.panel-default - .panel-heading.clearfix - = t(:domain_validation_rules) + .panel-heading + = t('.domain_validation') .table-responsive %table.table.table-hover.table-bordered.table-condensed - %thead - %tr - %th{class: 'col-xs-6'}= t(:setting) - %th{class: 'col-xs-6'}= t(:value) %tbody = render 'setting_row', var: :admin_contacts_min_count = render 'setting_row', var: :admin_contacts_max_count @@ -26,14 +22,10 @@ = render 'setting_row', var: :expire_pending_confirmation .panel.panel-default - .panel-heading.clearfix - = t(:domain_expiring) + .panel-heading + = t('.domain_expiration') .table-responsive %table.table.table-hover.table-bordered.table-condensed - %thead - %tr - %th{class: 'col-xs-6'}= t(:setting) - %th{class: 'col-xs-6'}= t(:value) %tbody = render 'setting_row', var: :days_to_renew_domain_before_expire = render 'setting_row', var: :expire_warning_period @@ -41,14 +33,10 @@ = render 'setting_row', var: :expiration_reminder_mail .panel.panel-default - .panel-heading.clearfix - = t(:other) + .panel-heading + = t('.other') .table-responsive %table.table.table-hover.table-bordered.table-condensed - %thead - %tr - %th{class: 'col-xs-6'}= t(:setting) - %th{class: 'col-xs-6'}= t(:value) %tbody = render 'setting_row', var: :transfer_wait_time = render 'setting_row', var: :ds_digest_type @@ -61,14 +49,10 @@ = render 'setting_row', var: :address_processing .panel.panel-default - .panel-heading.clearfix - = t(:billing_settings) + .panel-heading + = t('.billing') .table-responsive %table.table.table-hover.table-bordered.table-condensed - %thead - %tr - %th{class: 'col-xs-6'}= t(:setting) - %th{class: 'col-xs-6'}= t(:value) %tbody = render 'setting_row', var: :invoice_number_min = render 'setting_row', var: :invoice_number_max @@ -91,14 +75,10 @@ = render 'setting_row', var: :registry_swift .panel.panel-default - .panel-heading.clearfix - = t(:registry_settings) + .panel-heading + = t('.contacts') .table-responsive %table.table.table-hover.table-bordered.table-condensed - %thead - %tr - %th{class: 'col-xs-6'}= t(:setting) - %th{class: 'col-xs-6'}= t(:value) %tbody = render 'setting_row', var: :registry_juridical_name = render 'setting_row', var: :registry_reg_no @@ -113,4 +93,4 @@ .row .col-md-12.text-right - %button.btn.btn-primary=t(:save) + %button.btn.btn-primary=t('.submit_btn') diff --git a/config/locales/admin/menu.en.yml b/config/locales/admin/menu.en.yml index 1570200be..2c31a5193 100644 --- a/config/locales/admin/menu.en.yml +++ b/config/locales/admin/menu.en.yml @@ -2,6 +2,7 @@ en: admin: base: menu: + settings: Settings users: Users api_users: API users admin_users: Admin users diff --git a/config/locales/admin/settings.en.yml b/config/locales/admin/settings.en.yml new file mode 100644 index 000000000..047a1eb6a --- /dev/null +++ b/config/locales/admin/settings.en.yml @@ -0,0 +1,11 @@ +en: + admin: + settings: + index: + title: Settings + domain_validation: Domain validation + other: Other + domain_expiration: Domain expiration + billing: Billing + contacts: Contacts + submit_btn: Save diff --git a/config/locales/en.yml b/config/locales/en.yml index 4518533ef..2511d086b 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -264,13 +264,11 @@ en: required_ident_attribute_missing: "Required ident attribute missing: %{key}" code: 'Code' - value: 'Value' action: 'Action' edit: 'Edit' save: 'Save' log_out: 'Log out (%{user})' system: 'System' - settings: 'Settings' domains: 'Domains' registrars: 'Registrars' valid_to: 'Valid to' @@ -418,8 +416,6 @@ en: authentication_error: 'Authentication error' - setting: 'Setting' - transfer_requested: 'Transfer requested.' message_was_not_found: 'Message was not found' host_obj_is_not_allowed: 'hostObj object is not allowed' @@ -427,12 +423,6 @@ en: only_one_parameter_allowed: 'Only one parameter allowed: %{param_1} or %{param_2}' exactly_one_parameter_required: 'Exactly one parameter required: %{params}' required_parameter_missing_choice: 'Required parameter missing: %{param_1} or %{param_2}' - transfer_wait_time: 'Transfer wait time' - ns_min_count: 'Nameserver minimum count' - ns_max_count: 'Nameserver maximum count' - dnskeys_min_count: 'DNS keys minimum count' - dnskeys_max_count: 'DNS keys maximum count' - ds_data_allowed: 'DS data allowed' ds_data_with_key_allowed: 'Allow DS data with key' key_data_allowed: 'Allow key data' ds_digest_type: 'DS digest type' @@ -620,7 +610,6 @@ en: index: 'Index' ident: 'Ident' email: 'E-mail' - value: 'Value' phone: 'Phone' org_name: Org name country: Country @@ -808,32 +797,11 @@ en: tech: Tech contact valid: Valid object_is_not_eligible_for_renewal: 'Object is not eligible for renewal' - domain_expiring: 'Domain expiring' - domain_validation_rules: 'Domain validation rules' bank_statement_desc: 'Import file row will match only when matching following attributes:
ref number
payment amount
invoice number (the first numerical value in comment field)
.' create_bank_statement: 'Create bank statement' create_bank_transaction: 'Create bank transaction' create_new_invoice: 'Create new invoice' ip_is_not_whitelisted: 'IP is not whitelisted' - billing_settings: 'Billing settings' - registry_settings: 'Registry settings' - registry_billing_email: 'Billing e-mail' - registry_invoice_contact: 'Invoice contact' - registry_vat_no: 'VAT no.' - registry_vat_prc: 'VAT prc.' - registry_bank: 'Bank' - registry_iban: 'IBAN' - registry_swift: 'SWIFT' - registry_juridical_name: 'Juridical name' - registry_reg_no: 'Reg no.' - registry_email: 'E-mail' - registry_phone: 'Phone' - registry_url: 'URL' - registry_street: 'Street' - registry_city: 'City' - registry_state: 'State / Province' - registry_zip: 'Postcode' - registry_country_code: 'Country' billing_failure_credit_balance_low: 'Billing failure - credit balance low' create: 'Create' activity_type: 'Activity type'