mirror of
https://github.com/discourse/discourse.git
synced 2024-12-16 06:15:59 +08:00
ec03d135fa
clean up serializer, allow simplistic preview
15 lines
324 B
Ruby
15 lines
324 B
Ruby
class AdminBadgesSerializer < ApplicationSerializer
|
|
attributes :protected_system_fields, :triggers
|
|
has_many :badges, serializer: AdminBadgeSerializer
|
|
has_many :badge_groupings
|
|
has_many :badge_types
|
|
|
|
def protected_system_fields
|
|
object.protected_system_fields
|
|
end
|
|
|
|
def triggers
|
|
object.triggers
|
|
end
|
|
end
|