Module: Tasks::Otus::AreaAndNomen::AreaAndNomenHelper

Defined in:
app/helpers/tasks/otus/area_and_nomen/area_and_nomen_helper.rb

Instance Method Summary collapse

Instance Method Details

#otu_pagingObject



12
13
14
15
16
# File 'app/helpers/tasks/otus/area_and_nomen/area_and_nomen_helper.rb', line 12

def otu_paging
  if @otus.any?
    paginate(@otus, remote: true)
  end
end

#otu_paging_infoObject

<p><%= page_entries_info(@otus) %></p> <%= paginate @otus %>



4
5
6
7
8
9
10
# File 'app/helpers/tasks/otus/area_and_nomen/area_and_nomen_helper.rb', line 4

def otu_paging_info
  if @otus.any?
    page_entries_info(@otus)
  else
    'Displaying no otus'
  end
end

#rank_for_otu_select_tag(taxon_name: TaxonName.new, options: {}) ⇒ Object



18
19
20
# File 'app/helpers/tasks/otus/area_and_nomen/area_and_nomen_helper.rb', line 18

def rank_for_otu_select_tag(taxon_name: TaxonName.new, options: {})
  select_tag(:rank_class, options_for_select(RANKS_SELECT_OPTIONS, selected: taxon_name.rank_string, options: options), include_blank: true)
end