scinote-web/app/serializers/api/v1/project_serializer.rb
2021-06-07 10:34:58 +02:00

16 lines
336 B
Ruby

# frozen_string_literal: true
module Api
module V1
class ProjectSerializer < ActiveModel::Serializer
type :projects
attributes :name, :visibility, :start_date, :archived
belongs_to :project_folder, serializer: ProjectFolderSerializer
def start_date
object.created_at
end
end
end
end