remove week scaling for popular searches

This commit is contained in:
r888888888
2016-08-22 15:15:08 -07:00
parent d0bbe27217
commit ccf95957f9
3 changed files with 2 additions and 4 deletions

View File

@@ -1,6 +1,6 @@
class IntroPresenter
def each
PopularSearchService.new(Date.today, "week").each_search(20) do |query, count|
PopularSearchService.new(Date.today, "month").each_search(20) do |query, count|
yield(query, PostSets::Intro.new(query))
end
end

View File

@@ -22,17 +22,14 @@
<p style="margin-top: 2em;">
View by
<%= link_to "day", searches_explore_posts_path(:date => params[:date], :scale => "day") %> |
<%= link_to "week", searches_explore_posts_path(:date => params[:date], :scale => "week") %> |
<%= link_to "month", searches_explore_posts_path(:date => params[:date], :scale => "month") %>.
Back one
<%= link_to "day", searches_explore_posts_path(:date => 1.day.ago(@date), :scale => params[:scale]) %> |
<%= link_to "week", searches_explore_posts_path(:date => 1.week.ago(@date), :scale => params[:scale]) %> |
<%= link_to "month", searches_explore_posts_path(:date => 1.month.ago(@date), :scale => params[:scale]) %>.
Forward one
<%= link_to "day", searches_explore_posts_path(:date => 1.day.since(@date), :scale => params[:scale]) %> |
<%= link_to "week", searches_explore_posts_path(:date => 1.week.since(@date), :scale => params[:scale]) %> |
<%= link_to "month", searches_explore_posts_path(:date => 1.month.since(@date), :scale => params[:scale]) %>.
</p>
</div>

View File

@@ -3,6 +3,7 @@
$.post("<%= Danbooru.config.report_server %>/hits", {
key: "<%= key %>",
value: "<%= value %>",
uid: <%= CurrentUser.user.id.to_s %>,
sig: "<%= sig %>"
});
});