13 lines
401 B
Plaintext
13 lines
401 B
Plaintext
<%
|
|
content_for :section_title, "Questions"
|
|
%>
|
|
|
|
<main class="admin_tpl">
|
|
<% quizzes = @questions.group_by{ |q| q.quiz.name } %>
|
|
<% quizzes.each do |quiz, questions| %>
|
|
<h1><%= quiz %></h1>
|
|
<%= render partial: 'admin/question/table_list', locals: { questions: questions } %>
|
|
<%= link_to('Edit Quiz', admin_quiz_path(questions.first.quiz.to_i), { class: 'btn' }) %>
|
|
<% end %>
|
|
</main>
|