Class: Umwelt::Phase::Mapper
- Inherits:
-
Abstract::Mapper
- Object
- Abstract::Interactor
- Abstract::Mapper
- Umwelt::Phase::Mapper
- Defined in:
- lib/umwelt/phase/mapper.rb
Instance Method Summary collapse
Methods inherited from Abstract::Mapper
Methods inherited from Abstract::Interactor
Instance Method Details
#call(data) ⇒ Object
7 8 9 10 11 12 |
# File 'lib/umwelt/phase/mapper.rb', line 7 def call(data) @struct = fill( Struct::Phase, data.merge(finished_at: time(data[:finished_at])) ) end |
#time(str) ⇒ Object
14 15 16 |
# File 'lib/umwelt/phase/mapper.rb', line 14 def time(str) Time.parse str if str end |