simplify contributor report

This commit is contained in:
r888888888
2015-08-07 17:29:33 -07:00
parent e37775afc2
commit 23dfc455d5
2 changed files with 1 additions and 7 deletions

View File

@@ -3,7 +3,7 @@ require 'statistics2'
module Reports
class Contributors < User
def users
::User.where("users.level >= ? and users.post_upload_count >= 250", ::User::Levels::CONTRIBUTOR).order("created_at desc").limit(50).map {|x| Reports::UserPromotions::User.new(x)}
::User.where("users.level >= ? and users.post_upload_count >= 250", ::User::Levels::CONTRIBUTOR).order("created_at desc").map {|x| Reports::UserPromotions::User.new(x)}
end
end
end

View File

@@ -10,9 +10,6 @@
<th data-sort="string">User</th>
<th data-sort="int">Level</th>
<th data-sort="int">Uploads</th>
<th data-sort="int">score:3+</th>
<th data-sort="int" title="25% of uploads received this score or less">quartile score</th>
<th data-sort="int" title="50% of uploads received this score or less">median score</th>
<th data-sort="int">deletion</th>
</tr>
</thead>
@@ -23,9 +20,6 @@
<td><%= link_to_user user.user %></td>
<td data-sort-value="<%= user.level %>"><%= user.level_string %></td>
<td><%= link_to user.post_upload_count, posts_path(:tags => "uploader:#{user.name} order:random", :limit => 200) %></td>
<td><%= number_to_percentage user.confidence_interval_for(3), :precision => 0 %></td>
<td><%= user.quartile_score %></td>
<td><%= user.median_score %></td>
<td><%= link_to number_to_percentage(user.deletion_confidence_interval, :precision => 0), posts_path(:tags => "uploader:#{user.name} status:deleted", :limit => 200) %></td>
</tr>
<% end %>