Class: Stratagem::Model::Component::FormField
- Defined in:
- lib/stratagem/model/components/view.rb
Instance Attribute Summary collapse
-
#field_type ⇒ Object
readonly
Returns the value of attribute field_type.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #export ⇒ Object
-
#initialize(name, field_type) ⇒ FormField
constructor
A new instance of FormField.
Constructor Details
#initialize(name, field_type) ⇒ FormField
Returns a new instance of FormField.
176 177 178 179 |
# File 'lib/stratagem/model/components/view.rb', line 176 def initialize(name, field_type) @name = name @field_type = field_type end |
Instance Attribute Details
#field_type ⇒ Object (readonly)
Returns the value of attribute field_type.
174 175 176 |
# File 'lib/stratagem/model/components/view.rb', line 174 def field_type @field_type end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
174 175 176 |
# File 'lib/stratagem/model/components/view.rb', line 174 def name @name end |
Instance Method Details
#export ⇒ Object
181 182 183 |
# File 'lib/stratagem/model/components/view.rb', line 181 def export {:name => @name, :field_type => @field_type } end |