FEATURE: Button to reset new

This commit is contained in:
Robin Ward
2014-03-03 15:46:38 -05:00
parent 3abe84941f
commit f9cd354a2c
8 changed files with 60 additions and 1 deletions

View File

@@ -21,7 +21,8 @@ class TopicsController < ApplicationController
:merge_topic,
:clear_pin,
:autoclose,
:bulk]
:bulk,
:reset_new]
before_filter :consider_user_for_promotion, only: :show
@@ -281,6 +282,11 @@ class TopicsController < ApplicationController
render_json_dump topic_ids: changed_topic_ids
end
def reset_new
current_user.user_stat.update_column(:new_since, Time.now)
render nothing: true
end
private
def toggle_mute