wedding-planner/app/serializers/serializable_guest.rb

24 lines
406 B
Ruby
Raw Permalink Normal View History

2025-01-13 20:38:47 +00:00
# Copyright (C) 2024 Manuel Bustillo
# Copyright (C) 2024-2025 LibreWeddingPlanner contributors
2024-10-27 21:42:45 +00:00
# frozen_string_literal: true
class SerializableGuest < JSONAPI::Serializable::Resource
type 'guest'
attributes :id, :group_id, :status
attribute :name do
@object.name
end
attribute :group_name do
@object.group.name
end
2024-08-11 19:24:24 +02:00
attribute :status do
@object.status.capitalize
end
end