Sha256: 0c0aab994a888d59436b8e28c5b248fabe6128d4ffdd9b3350981150abeea6ea
Contents?: true
Size: 728 Bytes
Versions: 56
Compression:
Stored size: 728 Bytes
Contents
module Spree module V2 module Storefront class UserSerializer < BaseSerializer set_type :user attributes :email attribute :store_credits, &:total_available_store_credit attribute :completed_orders do |object| object.orders.complete.count end has_one :default_billing_address, id_method_name: :bill_address_id, object_method_name: :bill_address, record_type: :address, serializer: :address has_one :default_shipping_address, id_method_name: :ship_address_id, object_method_name: :ship_address, record_type: :address, serializer: :address end end end end
Version data entries
56 entries across 56 versions & 1 rubygems