Sha256: b5a9e3c788e31a70f30c2f26a907448f3cd80868b31d105f34eb596c55a6b0d1
Contents?: true
Size: 849 Bytes
Versions: 95
Compression:
Stored size: 849 Bytes
Contents
module ForestLiana class IntercomConversationSerializer include JSONAPI::Serializer attribute :created_at attribute :updated_at attribute :open attribute :read attribute :subject do object.conversation_message.subject end attribute :body do [object.conversation_message.body, object.link] end attribute :assignee do object.assignee.try(:email) end def self_link "/forest#{super}" end def type @options[:context][:type] || 'intercom-conversations' end def format_name(attribute_name) attribute_name.to_s end def unformat_name(attribute_name) attribute_name.to_s.underscore end def relationship_self_link(attribute_name) nil end def relationship_related_link(attribute_name) nil end end end
Version data entries
95 entries across 95 versions & 1 rubygems