Class: Rentvine::Property
- Inherits:
-
RentvineModel
- Object
- OpenStruct
- RentvineModel
- Rentvine::Property
- Defined in:
- lib/rentvine/model/property.rb
Instance Method Summary collapse
-
#initialize(data = {}) ⇒ Property
constructor
A new instance of Property.
- #to_rentvine_hash ⇒ Object
Methods inherited from RentvineModel
Constructor Details
#initialize(data = {}) ⇒ Property
Returns a new instance of Property.
3 4 5 |
# File 'lib/rentvine/model/property.rb', line 3 def initialize(data = {}) super(data) end |
Instance Method Details
#to_rentvine_hash ⇒ Object
7 8 9 10 11 12 13 14 |
# File 'lib/rentvine/model/property.rb', line 7 def to_rentvine_hash retval = super() unit = retval.delete(:unit) { property: retval, unit: unit } end |