Class: DynamicFieldsets::InstructionField
- Defined in:
- app/models/dynamic_fieldsets/instruction_field.rb
Overview
A special field used only for instruction No user input is included
Note that this field does not use the default header and footer partials for the fields
Instance Method Summary collapse
-
#form_partial_locals(args) ⇒ Hash
The label for the instruction plus the rest of the partial data.
-
#show_partial ⇒ Object
no answers possible, need an include for this?.
-
#update_field_records(fsa, fieldset_child, value) ⇒ Object
Do not update any options for the instruction.
-
#use_form_footer_partial? ⇒ Boolean
False because this field does not have the standard question: answer styling.
-
#use_form_header_partial? ⇒ Boolean
False because this field does not have the standard question: answer styling.
Methods inherited from Field
#collect_default_values, #collect_field_records_by_fsa_and_fsc, descendant_collection, descendants, #display_type, #form_footer_partial, #form_header_partial, #form_partial, #get_value_for_show, #get_values_using_fsa_and_fsc, #has_defaults?, #html_attribute_hash, #in_use?, #show_footer_partial, #show_header_partial, #show_partial_locals, #use_show_footer_partial?, #use_show_header_partial?, #uses_field_options?
Instance Method Details
#form_partial_locals(args) ⇒ Hash
Returns The label for the instruction plus the rest of the partial data.
23 24 25 26 27 |
# File 'app/models/dynamic_fieldsets/instruction_field.rb', line 23 def form_partial_locals(args) output = super output[:label] = self.label return output end |
#show_partial ⇒ Object
no answers possible, need an include for this?
9 10 11 |
# File 'app/models/dynamic_fieldsets/instruction_field.rb', line 9 def show_partial "/dynamic_fieldsets/show_partials/show_instruction" end |
#update_field_records(fsa, fieldset_child, value) ⇒ Object
Do not update any options for the instruction
30 31 32 |
# File 'app/models/dynamic_fieldsets/instruction_field.rb', line 30 def update_field_records(fsa, fieldset_child, value) # do nothing end |
#use_form_footer_partial? ⇒ Boolean
Returns False because this field does not have the standard question: answer styling.
18 19 20 |
# File 'app/models/dynamic_fieldsets/instruction_field.rb', line 18 def false end |
#use_form_header_partial? ⇒ Boolean
Returns False because this field does not have the standard question: answer styling.
13 14 15 |
# File 'app/models/dynamic_fieldsets/instruction_field.rb', line 13 def use_form_header_partial? false end |