improve links in ip addr search #2530

This commit is contained in:
r888888888
2015-10-15 12:19:16 -07:00
parent d8e84a90dc
commit 5eb08210b7
2 changed files with 4 additions and 6 deletions

View File

@@ -1,4 +1,4 @@
<%= link_to "Perform another search for accounts associated with these IP addresses", moderator_ip_addrs_path(:search => {:ip_addr => @results.map{|k, count| k}.join(",")}) %>
<p><%= link_to "Search for users with these IP addresses", moderator_ip_addrs_path(:search => {:ip_addr => @results.map {|k, count| k}.join(",")}) %></p>
<table class="striped">
<thead>
@@ -10,7 +10,7 @@
<tbody>
<% @results.each do |ip_address, count| %>
<tr>
<td><%= ip_address %></td>
<td><%= link_to moderator_ip_addrs_path(:search => {:ip_addr => ip_address}) %></td>
<td><%= count %></td>
</tr>
<% end %>

View File

@@ -1,18 +1,16 @@
<%= link_to "Perform another search for IP addresses associated with these accounts", moderator_ip_addrs_path(:search => {:user_id => @results.map{|k, count| k}.join(",")}) %>
<p><%= link_to "Search for IP addresses with these users", moderator_ip_addrs_path(:search => {:user_id => @results.map{|k, count| k}.join(",")}) %></p>
<table class="striped">
<thead>
<tr>
<th>User</th>
<th>User ID</th>
<th>Number of Occurrences</th>
</tr>
</thead>
<tbody>
<% @results.each do |user_id, count| %>
<tr>
<td><%= link_to_user User.find(user_id) %></td>
<td><%= user_id %></td>
<td><%= link_to User.id_to_name(user_id), moderator_ip_addrs_path(:search => {:user_id => user_id}) %></td>
<td><%= count %></td>
</tr>
<% end %>