Class: Lcms::Engine::CurriculumMap
- Inherits:
-
Object
- Object
- Lcms::Engine::CurriculumMap
- Defined in:
- app/entities/lcms/engine/curriculum_map.rb
Instance Attribute Summary collapse
-
#resource ⇒ Object
readonly
Returns the value of attribute resource.
Instance Method Summary collapse
-
#initialize(resource) ⇒ CurriculumMap
constructor
A new instance of CurriculumMap.
- #props ⇒ Object
Constructor Details
#initialize(resource) ⇒ CurriculumMap
Returns a new instance of CurriculumMap.
8 9 10 |
# File 'app/entities/lcms/engine/curriculum_map.rb', line 8 def initialize(resource) @resource = resource end |
Instance Attribute Details
#resource ⇒ Object (readonly)
Returns the value of attribute resource.
6 7 8 |
# File 'app/entities/lcms/engine/curriculum_map.rb', line 6 def resource @resource end |
Instance Method Details
#props ⇒ Object
12 13 14 15 16 |
# File 'app/entities/lcms/engine/curriculum_map.rb', line 12 def props return {} unless resource.present? { active: active_branch, results: curriculum } end |