Sha256: e8217ae1e0498d6a05800563d274c9011145d03bcd11921e1a49ce64e1c8a645
Contents?: true
Size: 524 Bytes
Versions: 14
Compression:
Stored size: 524 Bytes
Contents
# frozen_string_literal: true module Alchemy class EssencePictureSerializer < ActiveModel::Serializer self.root = false attributes :id, :picture_id, :caption, :title, :alt_tag, :css_class, :link, :created_at, :updated_at has_one :picture def link return if object.link.blank? { url: object.link, css_class: object.link_class_name, title: object.link_title, target: object.link_target } end end end
Version data entries
14 entries across 14 versions & 1 rubygems