1
0
mirror of https://github.com/mastodon/mastodon synced 2024-12-01 16:28:19 +09:00
mastodon/app/serializers/rest/admin/report_serializer.rb
2019-06-20 02:52:34 +02:00

17 lines
543 B
Ruby

# frozen_string_literal: true
class REST::Admin::ReportSerializer < ActiveModel::Serializer
attributes :id, :action_taken, :comment, :created_at, :updated_at
has_one :account, serializer: REST::Admin::AccountSerializer
has_one :target_account, serializer: REST::Admin::AccountSerializer
has_one :assigned_account, serializer: REST::Admin::AccountSerializer
has_one :action_taken_by_account, serializer: REST::Admin::AccountSerializer
has_many :statuses, serializer: REST::StatusSerializer
def id
object.id.to_s
end
end