Sha256: 8ec0a09446593c036725ad33b888a58cb9a3f62df53f0f9f619695bc50ab1325

Contents?: true

Size: 931 Bytes

Versions: 3

Compression:

Stored size: 931 Bytes

Contents

require_relative 'sale_order_data'
require_relative '../../gateway/AntiFraud/query_sale_anti_fraud_analysis_data'

class SaleData
  # Lista transações de cartão de crédito
  attr_accessor :CreditCardTransactionDataCollection

  # Lista as transações de boleto
  attr_accessor :BoletoTransactionDataCollection

  # Dados do pedido
  attr_accessor :OrderData

  # Chave do comprador. Utilzada para identificar um comprador no gateway
  attr_accessor :BuyerKey

  # Dados de serviço do antifraude
  attr_accessor :AntiFraudAnalysisData

  def initialize
    @CreditCardTransactionDataCollection = Array.new
    @BoletoTransactionDataCollection = Array.new
    @OrderData = SaleOrderData.new
    @AntiFraudAnalysisData = QuerySaleAntiFraudAnalysisData.new
  end

  def to_json
    hash = {}
    instance_variables.each {|var| hash[var.to_s.delete('@')] = instance_variable_get(var) }
    hash
  end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
mundipagg_sdk-1.0.2 lib/gateway/Sale/sale_data.rb
mundipagg_sdk-1.0.1 lib/gateway/Sale/sale_data.rb
mundipagg_sdk-1.0.0 lib/gateway/Sale/sale_data.rb