mirror of
https://github.com/internetee/registry.git
synced 2025-05-17 09:57:23 +02:00
Story#112601637 - admin contacts has filter to get only ident_country_code
This commit is contained in:
parent
2c059f9176
commit
58e383bd25
2 changed files with 8 additions and 1 deletions
|
@ -20,6 +20,8 @@ class Admin::ContactsController < AdminController
|
||||||
else
|
else
|
||||||
contacts = Contact.includes(:registrar)
|
contacts = Contact.includes(:registrar)
|
||||||
end
|
end
|
||||||
|
contacts = contacts.where("ident_country_code is null or ident_country_code=''") if params[:only_no_country_code].eql?('1')
|
||||||
|
|
||||||
|
|
||||||
normalize_search_parameters do
|
normalize_search_parameters do
|
||||||
@q = contacts.search(search_params)
|
@q = contacts.search(search_params)
|
||||||
|
|
|
@ -59,7 +59,12 @@
|
||||||
.form-group
|
.form-group
|
||||||
= label_tag t(:results_per_page)
|
= label_tag t(:results_per_page)
|
||||||
= text_field_tag :results_per_page, params[:results_per_page], class: 'form-control', placeholder: t(:results_per_page)
|
= text_field_tag :results_per_page, params[:results_per_page], class: 'form-control', placeholder: t(:results_per_page)
|
||||||
.col-md-3{style: 'padding-top: 25px;'}
|
.col-md-3
|
||||||
|
.form-group
|
||||||
|
= label_tag "Only wout ident CC?"
|
||||||
|
= check_box_tag :only_no_country_code, '1',params[:only_no_country_code].eql?('1'), class: 'form-control'
|
||||||
|
.row
|
||||||
|
.col-md-3{style: 'padding-top: 25px;float:right;'}
|
||||||
%button.btn.btn-primary
|
%button.btn.btn-primary
|
||||||
|
|
||||||
%span.glyphicon.glyphicon-search
|
%span.glyphicon.glyphicon-search
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue