Sha256: fc8d94376653e15f0ca86d5c635b11b52809e26a7c6c84a142877c3d1a854a22

Contents?: true

Size: 1.1 KB

Versions: 27

Compression:

Stored size: 1.1 KB

Contents

module ChargeBee
  class HostedPage < Model

  attr_accessor :id, :type, :url, :state, :failure_reason, :pass_thru_content, :embed, :created_at,
  :expires_at

  class Content < Result
  end

  def content
    if @values[:content].nil?
        nil
    else
        Content.new(@values[:content])
    end
  end

  # OPERATIONS
  #-----------

  def self.checkout_new(params, env=nil, headers={})
    Request.send('post', uri_path("hosted_pages","checkout_new"), params, env, headers)
  end

  def self.checkout_existing(params, env=nil, headers={})
    Request.send('post', uri_path("hosted_pages","checkout_existing"), params, env, headers)
  end

  def self.update_card(params, env=nil, headers={})
    Request.send('post', uri_path("hosted_pages","update_card"), params, env, headers)
  end

  def self.update_payment_method(params, env=nil, headers={})
    Request.send('post', uri_path("hosted_pages","update_payment_method"), params, env, headers)
  end

  def self.retrieve(id, env=nil, headers={})
    Request.send('get', uri_path("hosted_pages",id.to_s), {}, env, headers)
  end

  end # ~HostedPage
end # ~ChargeBee

Version data entries

27 entries across 27 versions & 1 rubygems

Version Path
chargebee-2.2.6 lib/chargebee/models/hosted_page.rb
chargebee-2.2.5 lib/chargebee/models/hosted_page.rb
chargebee-2.2.4 lib/chargebee/models/hosted_page.rb
chargebee-2.2.3 lib/chargebee/models/hosted_page.rb
chargebee-2.2.2 lib/chargebee/models/hosted_page.rb
chargebee-2.2.1 lib/chargebee/models/hosted_page.rb
chargebee-2.2.0 lib/chargebee/models/hosted_page.rb
chargebee-2.1.9 lib/chargebee/models/hosted_page.rb
chargebee-2.1.8 lib/chargebee/models/hosted_page.rb
chargebee-2.1.7 lib/chargebee/models/hosted_page.rb
chargebee-2.1.6 lib/chargebee/models/hosted_page.rb
chargebee-2.1.5 lib/chargebee/models/hosted_page.rb
chargebee-2.1.4 lib/chargebee/models/hosted_page.rb
chargebee-2.1.3 lib/chargebee/models/hosted_page.rb
chargebee-2.1.2 lib/chargebee/models/hosted_page.rb
chargebee-2.1.1 lib/chargebee/models/hosted_page.rb
chargebee-2.1.0 lib/chargebee/models/hosted_page.rb
chargebee-2.0.9 lib/chargebee/models/hosted_page.rb
chargebee-2.0.8 lib/chargebee/models/hosted_page.rb
chargebee-2.0.7 lib/chargebee/models/hosted_page.rb