Class: BigDoor::Currency
- Defined in:
- lib/big_door/currency.rb
Overview
This module provides Currency Resource object corresponding to /currency BigDoor API end point
Instance Method Summary collapse
-
#initialize(hash = {}) ⇒ Currency
constructor
Initialize new Currency object with optional Hash.
Methods inherited from Resource
all, #delete, #end_point, end_point, end_point_from_classname, #get_id, #instance_to_payload, #load, #response_to_instance, #save
Constructor Details
#initialize(hash = {}) ⇒ Currency
Initialize new Currency object with optional Hash
13 14 15 16 17 18 19 20 21 22 23 24 |
# File 'lib/big_door/currency.rb', line 13 def initialize( hash = {} ) $log.debug( "Currency init with hash = #{hash.inspect}") default_values = { 'currency_type_id' => 1, 'currency_type_title' => '', 'exchange_rate' => 1, 'relative_weight' => 1, } default_values.merge!( hash ) $log.debug( "Currency default_values = #{default_values.inspect}") super( default_values ) end |