Sha256: 8065eb1cd81780e765b7f748e221b38406308dd8df6086595b3a6e4dfb92458a

Contents?: true

Size: 831 Bytes

Versions: 1

Compression:

Stored size: 831 Bytes

Contents

object false

child @features, object_root: false, root: 'features' do
  attributes :id, :feature_type_id, :price, :price_type_id, :subtitle, :discount_percentage,
             :total_cost, :order_discount
  node :title do |feature|
    if feature.feature_type.multiple_variants?
      "#{feature.feature_type.title} #{feature.title}"
    else
      feature.title
    end
  end

  node :code do |feature|
    feature.feature_type.code
  end

  node :tip do |feature|
    feature.subtitle
  end
end

child @payment_types, object_root: false, root: 'payment_types' do
  attributes :id, :code, :title, :processing_type
end

child :rates do
  child @exchange_rates, object_root: false, root: 'currencies' do
    attributes :id, :currency, :value, :updated_at, :sort_order
    node :symbol do |rate|
      rate.symbol
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
translation_cms-0.1.5 app/views/account/transactions/pending_features.json.rabl