Class: Decidim::Votings::ContentBlocks::HighlightedVotingsCell

Inherits:
ContentBlocks::HighlightedParticipatorySpacesCell
  • Object
show all
Defined in:
app/cells/decidim/votings/content_blocks/highlighted_votings_cell.rb

Constant Summary collapse

BLOCK_ID =
"highlighted-votings"

Instance Method Summary collapse

Instance Method Details

#all_pathObject



19
20
21
# File 'app/cells/decidim/votings/content_blocks/highlighted_votings_cell.rb', line 19

def all_path
  Decidim::Votings::Engine.routes.url_helpers.votings_path
end

#highlighted_spacesObject



11
12
13
# File 'app/cells/decidim/votings/content_blocks/highlighted_votings_cell.rb', line 11

def highlighted_spaces
  @highlighted_spaces ||= OrganizationPrioritizedVotings.new(current_organization, current_user).query
end

#i18n_scopeObject



15
16
17
# File 'app/cells/decidim/votings/content_blocks/highlighted_votings_cell.rb', line 15

def i18n_scope
  "decidim.votings.pages.home.highlighted_votings"
end

#max_resultsObject



23
24
25
# File 'app/cells/decidim/votings/content_blocks/highlighted_votings_cell.rb', line 23

def max_results
  model.settings.max_results
end