Class: Decidim::Proposals::ProposalVoteCell

Inherits:
ViewModel
  • Object
show all
Includes:
Cell::ViewModel::Partial, DateRangeHelper, ViewHooksHelper
Defined in:
app/cells/decidim/proposals/proposal_vote_cell.rb

Instance Method Summary collapse

Constructor Details

#initializeProposalVoteCell

Returns a new instance of ProposalVoteCell.



19
20
21
22
23
24
# File 'app/cells/decidim/proposals/proposal_vote_cell.rb', line 19

def initialize(*)
  super

  @items ||= []
  @items << votes_count_item
end

Instance Method Details

#showObject



13
14
15
16
17
# File 'app/cells/decidim/proposals/proposal_vote_cell.rb', line 13

def show
  return if @items.blank?

  render
end