Class: CaseForm::Element::Label
- Defined in:
- lib/case_form/element/label.rb
Constant Summary
Constants inherited from Base
Instance Attribute Summary collapse
-
#method ⇒ Object
Returns the value of attribute method.
Attributes inherited from Base
Instance Method Summary collapse
-
#generate ⇒ Object
Generate label with defined text and HTML options.
-
#initialize(builder, method, options = {}) ⇒ Label
constructor
Initialize label object.
Methods included from CaseForm::ElementExt::Columnable
#columnable?, #object_column, #object_column_type?, #specific_method
Methods included from CaseForm::ElementExt::Validationable
#method_validations, #validationable?
Methods included from CaseForm::ElementExt::Naming
#object_human_model_name, #sanitized_object_name, #singularize_model_name
Constructor Details
#initialize(builder, method, options = {}) ⇒ Label
Initialize label object
13 14 15 16 |
# File 'lib/case_form/element/label.rb', line 13 def initialize(builder, method, ={}) @method = method super(builder, ) end |
Instance Attribute Details
#method ⇒ Object
Returns the value of attribute method.
9 10 11 |
# File 'lib/case_form/element/label.rb', line 9 def method @method end |
Instance Method Details
#generate ⇒ Object
Generate label with defined text and HTML options
20 21 22 |
# File 'lib/case_form/element/label.rb', line 20 def generate template.label(object_name, method, text, ) end |