Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Show holding pen guess scores #7974

Merged
merged 2 commits into from
Nov 3, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 32 additions & 1 deletion app/views/admin_raw_email/_holding_pen.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,33 @@
<% if @guessed_info_requests.any? %>
<div class="row">
<div class="accordion span11" id="guessed-requests">
<p>Guessed request:</p>
<p>Guessed request: </p>

<% if @guessed_info_requests.one? %>
<p>
<small class="muted">
Responses with a single guess are only automatically redelivered if
the guess meets a confidence threshold. This guess did not meet that
threshold.
</small>
</p>
<% end %>

<% @guessed_info_requests.each do |guess| %>
<div class="accordion-group">
<div class="accordion-heading">
<a href="#info_request_<%= guess.info_request.id %>" data-toggle="collapse"><i class="icon-chevron-right"></i></a>
<%= both_links(guess.info_request) %>

<span class="badge">
ID:
<%= number_to_percentage(guess.id_score * 100, precision: 0) %>
</span>

<span class="badge">
Idhash:
<%= number_to_percentage(guess.idhash_score * 100, precision: 0) %>
</span>
</div>

<div class="accordion-body collapse" id="info_request_<%= guess.info_request.id %>">
Expand All @@ -47,6 +68,16 @@
<td><strong>url_title:</strong></td>
<td><%= guess.info_request.url_title %></td>
</tr>

<tr>
<td><strong>ID Guess Score:</strong></td>
<td><%= number_to_percentage(guess.id_score * 100, precision: 0) %></td>
</tr>

<tr>
<td><strong>Idhash Guess Score:</strong></td>
<td><%= number_to_percentage(guess.idhash_score * 100, precision: 0) %></td>
</tr>
</table>

<p>
Expand Down
Loading