diff --git a/app/views/registrar/account_activities/_search_form.html.erb b/app/views/registrar/account_activities/_search_form.html.erb new file mode 100644 index 000000000..b5041a04c --- /dev/null +++ b/app/views/registrar/account_activities/_search_form.html.erb @@ -0,0 +1,46 @@ +
+
+ <%= search_form_for @q, url: [:registrar, :account_activities], html: { style: 'margin-bottom: 0;' } do |f| %> +
+
+
+ <%= f.label t(:activity_type) %> + <%= f.select :activity_type_in, AccountActivity.types_for_select, {}, class: 'form-control js-combobox', placeholder: t(:choose), multiple: true %> +
+
+ +
+
+ <%= f.label t(:description) %> + <%= f.search_field :description_cont, class: 'form-control', placeholder: t(:description), autocomplete: 'off' %> +
+
+
+ +
+
+
+ <%= f.label t(:receipt_date_from) %> + <%= f.search_field :created_at_gteq, value: params[:q][:created_at_gteq], class: 'form-control js-datepicker', placeholder: t(:receipt_date_from) %> +
+
+ +
+
+ <%= f.label t(:receipt_date_until) %> + <%= f.search_field :created_at_lteq, value: params[:q][:created_at_lteq], class: 'form-control js-datepicker', placeholder: t(:receipt_date_until) %> +
+
+ +
+ + <%= link_to(t('.reset_btn'), registrar_account_activities_path, class: 'btn btn-default') %> +
+
+ <% end %> +
+
diff --git a/app/views/registrar/account_activities/index.html.erb b/app/views/registrar/account_activities/index.html.erb index 73e966b51..257c4d306 100644 --- a/app/views/registrar/account_activities/index.html.erb +++ b/app/views/registrar/account_activities/index.html.erb @@ -5,48 +5,7 @@ <%= render 'shared/title', name: t(:account_activity) %> -
-
- <%= search_form_for @q, url: [:registrar, :account_activities], html: { style: 'margin-bottom: 0;' } do |f| %> -
-
-
- <%= f.label t(:activity_type) %> - <%= f.select :activity_type_in, AccountActivity.types_for_select, {}, class: 'form-control js-combobox', placeholder: t(:choose), multiple: true %> -
-
-
-
- <%= f.label t(:description) %> - <%= f.search_field :description_cont, class: 'form-control', placeholder: t(:description), autocomplete: 'off' %> -
-
-
-
-
-
- <%= f.label t(:receipt_date_from) %> - <%= f.search_field :created_at_gteq, value: params[:q][:created_at_gteq], class: 'form-control js-datepicker', placeholder: t(:receipt_date_from) %> -
-
-
-
- <%= f.label t(:receipt_date_until) %> - <%= f.search_field :created_at_lteq, value: params[:q][:created_at_lteq], class: 'form-control js-datepicker', placeholder: t(:receipt_date_until) %> -
-
-
- - <%= link_to(t('.reset_btn'), registrar_account_activities_path, class: 'btn btn-default') %> -
-
- <% end %> -
-
+<%= render 'search_form' %>
diff --git a/config/locales/registrar/account_activities.en.yml b/config/locales/registrar/account_activities.en.yml index 27d0150d6..bba527c9c 100644 --- a/config/locales/registrar/account_activities.en.yml +++ b/config/locales/registrar/account_activities.en.yml @@ -1,5 +1,5 @@ en: registrar: account_activities: - index: + search_form: reset_btn: Reset