Class: Decidim::ParticipatoryProcesses::FilteredParticipatoryProcessesCell

Inherits:
ViewModel
  • Object
show all
Includes:
CardHelper, FilterResource
Defined in:
decidim-participatory_processes/app/cells/decidim/participatory_processes/filtered_participatory_processes_cell.rb

Overview

This cell renders a set of filtered participatory processes from a base relation provided by the model

The `model` must be a relation of participatory processes

Available options:

  • `default_date_filter` => The date filter to use if not given by

    params. If not provided is inferred from the model relation
    

Example:

cell(

"decidim/participatory_processes/filtered_participatory_processes",
group.participatory_processes.published,
default_filter: "active"

)

Instance Method Summary collapse

Methods included from CardHelper

#card_for

Instance Method Details

#elementsObject


26
27
28
# File 'decidim-participatory_processes/app/cells/decidim/participatory_processes/filtered_participatory_processes_cell.rb', line 26

def elements
  @elements ||= search.result
end