Class: Tasks::TaxonNames::AuthorSummaryController

Inherits:
ApplicationController
  • Object
show all
Includes:
TaskControllerConfiguration
Defined in:
app/controllers/tasks/taxon_names/author_summary_controller.rb

Instance Method Summary collapse

Methods included from TaskControllerConfiguration

#set_is_task_controller

Instance Method Details

#indexObject

GET



5
6
7
8
9
10
# File 'app/controllers/tasks/taxon_names/author_summary_controller.rb', line 5

def index
  @taxon_names_query = ::Queries::TaxonName::Filter.new(params[:taxon_name_query])
  @taxon_names = @taxon_names_query.all.left_joins(:taxon_name_authors)
  @author_data = ApplicationController.helpers.summarize_authors_by_year(@taxon_names)
  @coauthorship_data = ApplicationController.helpers.author_coauthorship_data(@taxon_names)
end