<% content_for :heading do %>
- <h1>Report a new Issue for <%= reportable_url(@issue.reportable) %></h1>
+ <h1>Report <%= reportable_url(@issue.reportable) %></h1>
<% end %>
<%= form_for(@issue) do |f| %>
<div class='form-row'>
<p>Select one (or more) reasons for your report:</p>
-
- <div class="new-report-form">
- <div class="new-report-checkbox">
- <%= check_box_tag :spam, "[SPAM]" %>
- </div>
- <div class="new-report-string">
- <%= label_tag "This #{@issue.reportable.class.name} is/contains spam." %> <br/>
- </div>
- </div>
- <br/>
-
- <div class="new-report-form">
- <div class="new-report-checkbox">
- <%= check_box_tag :offensive, "[OFFENSIVE]" %>
- </div>
- <div class="new-report-string">
- <%= label_tag "This #{@issue.reportable.class.name} is obscene/offensive." %> <br/>
- </div>
- </div>
- <br/>
-
- <div class="new-report-form">
- <div class="new-report-checkbox">
- <%= check_box_tag :threat, "[THREAT]" %>
- </div>
- <div class="new-report-string">
- <%= label_tag "This #{@issue.reportable.class.name} contains a threat." %> <br/>
- </div>
- </div>
- <br/>
- <% if @issue.reportable.class.name == "User" %>
+ <% @report_strings_yaml.each do |k,v| %>
<div class="new-report-form">
<div class="new-report-checkbox">
- <%= check_box_tag :vandal, "[VANDAL]" %>
+ <%= radio_button_tag :report_type, v[:type].to_s %>
</div>
<div class="new-report-string">
- <%= label_tag "This #{@issue.reportable.class.name} is a vandal." %> <br/>
+ <%= label_tag v[:details].to_s %> <br/>
</div>
</div>
<br/>
- <% end %>
-
- <div class="new-report-form">
- <div class="new-report-checkbox">
- <%= check_box_tag :other, "[OTHER]" %>
- </div>
- <div class="new-report-string">
- <%= label_tag "Other." %> <br/>
- </div>
- </div>
- <br/>
-
- <label class="standard-label"><b><%= t 'issue.new.message' -%>: </b></label> <br/>
- <%= text_area :report, :details, :cols => 80, :rows => 20, placeholder: "Please provide some more details into the problem. (This field cannot be left blank!)" %>
+ <% end %>
+
+ <label class="standard-label"><b><%= t 'issue.new.message' %>: </b></label> <br/>
+ <%= text_area :report, :details, :cols => 80, :rows => 20, placeholder: t('issues.new.details'), required: true %>
</div>
<div class='buttons'>