Project

General

Profile

RE: Plugin tutorial - Pools from project menu - error aft... » index.html.erb

Tam M, 2018-12-14 21:15

 
<h2>Polls Header</h2>

<% html_title "The Polls Page" %>

<% @polls.each do |poll| %>
<p>
<%= poll.question %>
<%= link_to 'Yes', { :action => 'vote', :id => poll[:id], :answer => 'yes', :project_id => params[:project_id] }, :method => :post, :class => 'vote yes' %> (<%= poll.yes %>)
<%= link_to 'No', { :action => 'vote', :id => poll[:id], :answer => 'no', :project_id => params[:project_id] }, :method => :post, :class => 'vote no' %> (<%= poll.no %>)
</p>
<% end %>

<% content_for :header_tags do %>
<%= stylesheet_link_tag 'voting', :plugin => 'tutorial_polls' %>
<% end %>
(1-1/2)