Sha256: 3fb88026890f233e4e22c691ee8f567cc5d5a4aef5cd5c02a8a6af6b3f4a7586
Contents?: true
Size: 898 Bytes
Versions: 1
Compression:
Stored size: 898 Bytes
Contents
class Exchequer::Card attr_accessor :first_name, :last_name, :full_number, :cvv, :expiration_month, :expiration_year, :billing_address, :billing_city, :billing_state, :billing_zip, :billing_country def initialize(params = {}) params ||= {} params.keys.each do |key| send "#{key}=", params[key] end end def errors @errors ||= ActiveModel::Errors.new(self) end def to_hash { 'first_name' => first_name, 'last_name' => last_name, 'full_number' => full_number, 'cvv' => cvv, 'expiration_month' => expiration_month, 'expiration_year' => expiration_year, 'billing_address' => billing_address, 'billing_city' => billing_city, 'billing_state' => billing_state, 'billing_zip' => billing_zip, 'billing_country' => billing_country } end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
exchequer-0.1.0 | lib/exchequer/card.rb |