Class: Answers::UiObjectsRelatableCategoryDropDownView
- Inherits:
-
UiObjectView
- Object
- Mustache
- MustacheRails
- UiObjectView
- Answers::UiObjectsRelatableCategoryDropDownView
- Defined in:
- lib/question_chain/models/answers/ui_objects_relatable_category_drop_down_view.rb
Instance Method Summary collapse
-
#options ⇒ Object
@return [Array<Hash<value => value, name => name>>].
- #prompt ⇒ Object
Methods inherited from UiObjectView
#css_classes, #default_styles, #default_value, #disabled, #dom_id, #extra_info, #has_extra_info, #input_id, #label, #name, #ui_object_name, #value
Methods inherited from MustacheRails
#initialize, #method_missing, #render, #respond_to?, #template=
Constructor Details
This class inherits a constructor from MustacheRails
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class MustacheRails
Instance Method Details
#options ⇒ Object
@return [Array<Hash<value => value, name => name>>]
9 10 11 12 13 14 15 |
# File 'lib/question_chain/models/answers/ui_objects_relatable_category_drop_down_view.rb', line 9 def if answer_params ui_object..map{|option| option.merge!(:selected => option["value"].to_s == value.to_s)} else ui_object. end end |
#prompt ⇒ Object
4 5 6 |
# File 'lib/question_chain/models/answers/ui_objects_relatable_category_drop_down_view.rb', line 4 def prompt ui_object.prompt end |