Sha256: 5694fade64fc595841653ddc62bde763c3549c7df298a3d8d195206ca1a1fd8a

Contents?: true

Size: 391 Bytes

Versions: 1

Compression:

Stored size: 391 Bytes

Contents

module Spree
  class TaxonSerializer < Spree::BaseSerializer
    attributes :name, :permalink, :position, :description, :meta_title, :links,
               :meta_description, :meta_keywords, :depth

    belongs_to :taxonomy
    belongs_to :parent, serializer: TaxonSerializer
    has_many :children, serializer: TaxonSerializer

    def links
      image_links object.icon
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
solidus_json_api-0.3.1 app/serializers/spree/taxon_serializer.rb