Fix #4106: Allow moderators to IP ban subnets.
This commit is contained in:
@@ -14,8 +14,8 @@
|
||||
<tbody>
|
||||
<% @ip_bans.each do |ip_ban| %>
|
||||
<tr>
|
||||
<td><%= link_to_ip ip_ban.ip_addr %></td>
|
||||
<td><%= ip_ban.creator.name %></td>
|
||||
<td><%= link_to_ip ip_ban.subnetted_ip %></td>
|
||||
<td><%= link_to_user ip_ban.creator %></td>
|
||||
<td><%= ip_ban.reason %></td>
|
||||
<td><%= link_to "Unban", ip_ban_path(ip_ban), :remote => true, :method => :delete, :data => {:confirm => "Do your really want to unban #{ip_ban.ip_addr}?"} %></td>
|
||||
</tr>
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
<%= error_messages_for "ip_ban" %>
|
||||
|
||||
<%= simple_form_for(@ip_ban) do |f| %>
|
||||
<%= f.input :ip_addr, :label => "IP Address", :as => :string %>
|
||||
<%= f.input :reason, :input_html => {:size => "50x5"} %>
|
||||
<%= f.input :ip_addr, label: "IP Address", as: :string, hint: "Add /24 to ban a subnet. Example: 1.2.3.4/24" %>
|
||||
<%= f.input :reason %>
|
||||
<%= f.button :submit, "Submit" %>
|
||||
<% end %>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user