From e6914babee0859c92e7060e9147ed4a5b7bcca2e Mon Sep 17 00:00:00 2001 From: benji Date: Fri, 11 Sep 2015 21:14:35 +0200 Subject: [PATCH] Select2 on peer --- app/views/users/show.html.haml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/app/views/users/show.html.haml b/app/views/users/show.html.haml index b09ae2a..2c69085 100644 --- a/app/views/users/show.html.haml +++ b/app/views/users/show.html.haml @@ -41,13 +41,14 @@ .row .col-md-4 .input-listen{ 'data-input-type': 'text', 'data-filter-name': 'Issuer' } - = grouped_collection_select :nil, :nil, [User, Client], :all, :name, :name, :name, + = grouped_collection_select nil, nil, [User, Client], :all, :name, :name, :name, { include_blank: true }, { data: { placeholder: "Filter on Issuer" }, class: "select2-selector form-control" } .col-md-4 .input-listen{ 'data-input-type': 'text', 'data-filter-name': 'Peer' } - %input{type: 'text', placeholder: 'Filter on Peer', - class: "form-control" } + = select_tag nil, + options_from_collection_for_select(User.all.order(:name), :name, :name), + include_blank: true, class: "select2-selector form-control", data: { placeholder: "Filter on Peer" } .col-md-4 .input-listen{ 'data-input-type': 'text', 'data-filter-name': 'Message' } %input{type: 'text', placeholder: 'Filter on Message',