discourse/app/serializers/topic_status_update_serializer.rb
Guo Xiang Tan 34b7bee568 FEATURE: Allow admin to auto reopen at topic.
* This commit also introduces a `TopicStatusUpdate`
  model to support other forms of deferred topic
  status update in the future.
2017-03-31 11:14:18 +08:00

12 lines
263 B
Ruby

class TopicStatusUpdateSerializer < ApplicationSerializer
attributes :id,
:execute_at,
:duration,
:based_on_last_post,
:status_type
def status_type
TopicStatusUpdate.types[object.status_type]
end
end