Class: UserPostTopicBookmarkBaseSerializer

Inherits:
UserBookmarkBaseSerializer show all
Includes:
PostItemExcerpt, TopicTagsMixin
Defined in:
app/serializers/user_post_topic_bookmark_base_serializer.rb

Instance Method Summary collapse

Methods included from PostItemExcerpt

#cooked, #excerpt, #include_truncated?, included, #truncated

Methods included from TopicTagsMixin

#include_tags?, included, #tags, #tags_descriptions, #topic

Methods inherited from UserBookmarkBaseSerializer

#bookmarkable_url, #cooked, #excerpt, #include_reminder_at_ics_end?, #include_reminder_at_ics_start?, #reminder_at_ics_end, #reminder_at_ics_start, #user

Methods inherited from ApplicationSerializer

expire_cache_fragment!, fragment_cache

Methods inherited from ActiveModel::Serializer

#include!

Instance Method Details

#archetypeObject



37
38
39
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 37

def archetype
  topic.archetype
end

#archivedObject



41
42
43
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 41

def archived
  topic.archived
end

#bumped_atObject



53
54
55
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 53

def bumped_at
  topic.bumped_at
end

#category_idObject



33
34
35
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 33

def category_id
  topic.category_id
end

#closedObject



45
46
47
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 45

def closed
  topic.closed
end

#fancy_titleObject



29
30
31
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 29

def fancy_title
  topic.fancy_title
end

#highest_post_numberObject



49
50
51
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 49

def highest_post_number
  scope.is_whisperer? ? topic.highest_staff_post_number : topic.highest_post_number
end

#slugObject



57
58
59
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 57

def slug
  topic.slug
end

#titleObject



25
26
27
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 25

def title
  topic.title
end

#topic_idObject



21
22
23
# File 'app/serializers/user_post_topic_bookmark_base_serializer.rb', line 21

def topic_id
  topic.id
end