mirror of
https://github.com/manyfold3d/manyfold.git
synced 2026-10-22 03:32:18 -05:00
15 lines
393 B
Ruby
15 lines
393 B
Ruby
module DataPackage
|
|
class CreatorSerializer < BaseSerializer
|
|
def serialize
|
|
{
|
|
title: @object.name,
|
|
path: Rails.application.routes.url_helpers.url_for(@object),
|
|
roles: ["creator"],
|
|
caption: @object.caption,
|
|
description: @object.notes,
|
|
links: @object.links.map { |it| LinkSerializer.new(it).serialize }
|
|
}.compact
|
|
end
|
|
end
|
|
end
|