Revert "fixes #2530: improved ip addr search"

This reverts commit 1eb2d515fd.

Conflicts:
	app/views/moderator/ip_addrs/index.html.erb
This commit is contained in:
r888888888
2015-10-15 12:12:21 -07:00
parent 821c7bc2a5
commit d8e84a90dc
4 changed files with 7 additions and 54 deletions

View File

@@ -2,24 +2,11 @@
<div id="a-index">
<h1>IP Addresses</h1>
<p>The following users share IP addresses used by <%= params[:search][:user_name] %>. This searches across comments, post changes, note changes, pool changes, wiki changes, and dmails over the past 3 months.</p>
<table class="striped">
<thead>
<tr>
<th>User</th>
<th>Count</th>
</tr>
</thead>
<tbody>
<% @search.find_common_users.each do |user_id, count| %>
<tr>
<td><%= link_to User.id_to_name(user_id), user_path(user_id) %></td>
<td><%= count %></td>
</tr>
<% end %>
</tbody>
</table>
<% if params[:search][:user_id].present? || params[:search][:user_name].present? %>
<%= render "ip_listing" %>
<% else %>
<%= render "user_listing" %>
<% end %>
</div>
</div>

View File

@@ -4,6 +4,7 @@
<%= form_tag(moderator_ip_addrs_path, :method => :get, :class => "simple_form") do %>
<%= search_field "user_name", :label => "User" %>
<%= search_field "ip_addr", :label => "IP Addr" %>
<%= submit_tag "Search" %>
<% end %>
</div>