Class: Kiss::Form::SubmitField
- Inherits:
-
MultiChoiceField
- Object
- Field
- MultiChoiceField
- Kiss::Form::SubmitField
- Defined in:
- lib/kiss/form/field.rb
Constant Summary
Constants inherited from Field
Instance Method Summary collapse
- #element_html(*args) ⇒ Object
- #elements_html(attrs = {}) ⇒ Object
-
#initialize(*args) ⇒ SubmitField
constructor
A new instance of SubmitField.
Methods inherited from MultiChoiceField
#column_layout, #display_to_s, #form=, #has_option_value?, #option_pairs, #options_keys, #other_field_html, #validate
Methods inherited from Field
#add_error, #content_tag_html, #debug, #errors_html, #html, #input_tag_html, #method_missing, #param, #require_value, #reset, #set_value_to_hash, #set_value_to_object, #tag_html, #tag_start_html, #tip_html, #type, #validate, #value, #value_string, #value_to_s
Constructor Details
#initialize(*args) ⇒ SubmitField
Returns a new instance of SubmitField.
580 581 582 583 |
# File 'lib/kiss/form/field.rb', line 580 def initialize(*args) @_save = false super(*args) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Kiss::Form::Field
Instance Method Details
#element_html(*args) ⇒ Object
585 586 587 |
# File 'lib/kiss/form/field.rb', line 585 def element_html(*args) elements_html(*args).join(' ') end |
#elements_html(attrs = {}) ⇒ Object
589 590 591 592 593 |
# File 'lib/kiss/form/field.rb', line 589 def elements_html(attrs = {}) @_options.map do |option| input_tag_html(attrs.merge( :value => value_to_s(option) )) end end |