Class: Decidim::DecidimAwesome::Voting::VotingCardsCounterCell

Inherits:
VotingCardsBaseCell show all
Defined in:
app/cells/decidim/decidim_awesome/voting/voting_cards_counter_cell.rb

Instance Method Summary collapse

Methods inherited from VotingCardsBaseCell

#component_settings, #current_component, #current_vote, #proposal, #sanitized_title, #user_voted_weight

Instance Method Details

#resource_pathObject



11
12
13
# File 'app/cells/decidim/decidim_awesome/voting/voting_cards_counter_cell.rb', line 11

def resource_path
  resource_locator(model).path
end

#showObject



7
8
9
# File 'app/cells/decidim/decidim_awesome/voting/voting_cards_counter_cell.rb', line 7

def show
  render :show
end

#vote_btn_classObject



15
16
17
# File 'app/cells/decidim/decidim_awesome/voting/voting_cards_counter_cell.rb', line 15

def vote_btn_class
  user_voted_weight ? "weight_#{user_voted_weight.to_i}" : "hollow"
end