From 0bdb0f17b57b1b80397d124dbdcfd4ec407d7a0a Mon Sep 17 00:00:00 2001 From: Martin Lensment Date: Wed, 29 Jul 2015 17:26:59 +0300 Subject: [PATCH] Search domains WIP #2122 --- app/views/admin/domains/index.haml | 32 ++++++++++++++++++++++++------ config/locales/en.yml | 5 ++++- 2 files changed, 30 insertions(+), 7 deletions(-) diff --git a/app/views/admin/domains/index.haml b/app/views/admin/domains/index.haml index 8f60fb2a6..948939f4f 100644 --- a/app/views/admin/domains/index.haml +++ b/app/views/admin/domains/index.haml @@ -2,16 +2,36 @@ .row .col-md-12 - = search_form_for [:admin, @q], html: { class: 'form-horizontal' } do |f| - .col-md-11 - .form-group - = f.search_field :name_cont, class: 'form-control' - .col-md-1.text-right.text-center-xs - .form-group + = search_form_for [:admin, @q], html: { style: 'margin-bottom: 0;', class: 'js-form' } do |f| + .row + .col-md-4 + .form-group + = f.label :name + = f.search_field :name_cont, class: 'form-control', placeholder: t(:name) + .col-md-4 + .form-group + = f.label t(:registrar) + = f.select :registrar_id_eq, Registrar.all.map { |x| [x, x.id] }, {}, class: 'form-control selectize', placeholder: t(:choose) + .col-md-4 + .form-group + = f.label t(:registrant_ident) + = f.search_field :registrant_ident_eq, class: 'form-control', placeholder: t(:registrant_ident) + .row + .col-md-3 + .form-group + = f.label t(:valid_to_from) + = f.search_field :valid_to_gteq, class: 'form-control datepicker', placeholder: t(:valid_to_from), autocomplete: 'off' + .col-md-3 + .form-group + = f.label t(:valid_to_until) + = f.search_field :valid_to_lteq, class: 'form-control datepicker', placeholder: t(:valid_to_until), autocomplete: 'off' + .col-md-3{style: 'padding-top: 25px;'} %button.btn.btn-primary   %span.glyphicon.glyphicon-search   + %button.btn.btn-default.js-reset-form + = t(:clear_fields) %hr .row .col-md-12 diff --git a/config/locales/en.yml b/config/locales/en.yml index 97a17e3da..d5a5c938b 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -785,7 +785,7 @@ en: registrant_updated_notification_for_old_registrant_subject: 'Domeeni %{name} registreerija vahetus teostatud / Registrant change of %{name} has been finished.' domain_pending_deleted_subject: "Kinnitustaotlus domeeni %{name} kustutamiseks .ee registrist / Application for approval for deletion of %{name}" pending_delete_rejected_notification_subject: "Domeeni %{name} kustutamise taotlus tagasi lükatud / %{name) deletion declined" - pending_delete_expired_notification_subject: "Domeeni %{name} kustutamise taotlus on tühistatud / %{name} deletion cancelled" + pending_delete_expired_notification_subject: "Domeeni %{name} kustutamise taotlus on tühistatud / %{name} deletion cancelled" delete_confirmation_subject: "Domeeni %{name} kustutatud / %{name} deleted" whois: WHOIS login_failed_check_id_card: 'Log in failed, check ID card' @@ -886,3 +886,6 @@ en: active_price_for_this_operation_is: 'Active price for this operation is %{price}' active_price_missing_for_this_operation: 'Active price missing for this operation!' log_out_: 'Log out' + valid_to_from: 'Valid to from' + valid_to_until: 'Valid to until' + registrant_ident: 'Registrant ident'