<% if question.question_options.any? %>
  <% if process.debate_phase.open? && !answer.persisted? && can?(:create, Legislation::Answer) %>

    <%= form_for answer, url: legislation_process_question_answers_path(process, question, answer), remote: true, html: { class: "controls-stacked" } do |f| %>
      <% question.question_options.each do |question_option| %>
        <label class="control radio <%= "is-active" if @answer.legislation_question_option_id == question_option.id %>">
          <%= f.radio_button :legislation_question_option_id, question_option.id, label: false %>
          <span class="control-indicator"></span>
          <%= question_option.value %>
        </label>
      <% end %>
      <%= f.submit t("legislation.questions.show.answer_question"), class: "button" %>
    <% end %>

  <% else %>

    <form class="controls-stacked disabled">
      <% question.question_options.each do |question_option| %>
        <label class="control radio <%= "is-active" if answer.persisted? && (answer.legislation_question_option_id == question_option.id) %>">
          <input id="quiz-1" name="radio" type="radio" disabled="true">
          <span class="control-indicator"></span>
          <%= question_option.value %>
        </label>
      <% end %>
    </form>

  <% end %>

  <%= render "participation_not_allowed" %>
<% end %>
