FEATURE: Bulk reset read status.

This commit is contained in:
Robin Ward
2014-02-21 13:03:50 -05:00
parent 7a07f14dfc
commit a07e9f7e71
9 changed files with 41 additions and 19 deletions

View File

@ -8,7 +8,7 @@ class TopicsBulkAction
end
def self.operations
%w(change_category close change_notification_level)
%w(change_category close change_notification_level reset_read)
end
def perform!
@ -19,6 +19,10 @@ class TopicsBulkAction
private
def reset_read
PostTiming.destroy_for(@user.id, @topic_ids)
end
def change_category
topics.each do |t|
if guardian.can_edit?(t)