socialforge/app/views/poll/poll_result.html.erb

31 lines
1.4 KiB
Plaintext

<%= stylesheet_link_tag 'polls', :media => 'all' %>
<div class="homepageRight mt0 ml10">
<div class="resources" >
<div class="testStatus">
<h1 class="ur_page_title">
<%= @poll.polls_name.empty? ? l(:label_poll_new) : @poll.polls_name %>
</h1>
<div class="testDesEdit mt5"><%= @poll.polls_description.nil? ? "" : @poll.polls_description.html_safe%></div>
</div>
<% @poll_questions.each do |poll_question|%>
<div class="testStatus">
<div id="poll_questions_<%= poll_question.id%>">
<div id="show_poll_questions_<%= poll_question.id %>">
<% if poll_question.question_type == 1%>
<%= render :partial => 'show_MC_result', :locals => {:poll_question => poll_question} %>
<% elsif poll_question.question_type == 2%>
<%= render :partial => 'show_MCQ_result', :locals => {:poll_question => poll_question} %>
<% elsif poll_question.question_type == 3%>
<%= render :partial => 'show_single_result', :locals => {:poll_question => poll_question} %>
<% elsif poll_question.question_type == 4%>
<%= render :partial => 'show_mulit_result', :locals => {:poll_question => poll_question} %>
<% end%>
</div>
</div>
</div>
<% end%>
<div class="cl"></div>
</div>
</div><!--问卷内容end-->