Module: SearchesHelper

Defined in:
app/helpers/searches_helper.rb

Instance Method Summary collapse

Instance Method Details

#search_membership_type_options(membership_types, selected = nil) ⇒ Object



2
3
4
5
6
7
8
9
10
11
12
# File 'app/helpers/searches_helper.rb', line 2

def search_membership_type_options(membership_types, selected=nil)
  options = [
    ['All Membership Types', -1]
  ]

  membership_types.each do |type|
    options << [type.name, type.id]
  end

  options_for_select(options, selected)
end