Sha256: 2be3cb7df10359675a03d368a8054b8a1b7fac5973cf389cf4f500f862173892
Contents?: true
Size: 730 Bytes
Versions: 5
Compression:
Stored size: 730 Bytes
Contents
# frozen_string_literal: true module SocialNetworking module Serializers # Serializes OnTheMindStatement models. class OnTheMindStatementSerializer < Serializer def to_serialized { className: "SocialNetworking::OnTheMindStatement", id: model.id, createdAt: model.created_at, createdAtRaw: model.created_at.to_i, participantId: model.participant_id, isAdmin: model.participant.is_admin, summary: "said #{model.description}", description: model.description, comments: CommentSerializer.from_collection(model.comments), likes: LikeSerializer.from_collection(model.likes) } end end end end
Version data entries
5 entries across 5 versions & 1 rubygems