20 lines
290 B
Ruby
20 lines
290 B
Ruby
|
class ReviewableTopicSerializer < ApplicationSerializer
|
||
|
attributes(
|
||
|
:id,
|
||
|
:title,
|
||
|
:fancy_title,
|
||
|
:slug,
|
||
|
:archived,
|
||
|
:closed,
|
||
|
:visible,
|
||
|
:archetype,
|
||
|
:relative_url,
|
||
|
:stats,
|
||
|
:reviewable_score
|
||
|
)
|
||
|
|
||
|
def stats
|
||
|
@options[:stats][object.id]
|
||
|
end
|
||
|
end
|