Class: UcbRails::Renderer::LpsTypeaheadSearchField

Inherits:
Base
  • Object
show all
Defined in:
app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb

Instance Attribute Summary collapse

Attributes inherited from Base

#options, #template

Instance Method Summary collapse

Constructor Details

#initialize(template, options = {}) ⇒ LpsTypeaheadSearchField

Returns a new instance of LpsTypeaheadSearchField.



8
9
10
11
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 8

def initialize(template, options={})
  super
  parse_options
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class UcbRails::Renderer::Base

Instance Attribute Details

#hintObject

Returns the value of attribute hint.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def hint
  @hint
end

#labelObject

Returns the value of attribute label.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def label
  @label
end

#nameObject

Returns the value of attribute name.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def name
  @name
end

#placeholderObject

Returns the value of attribute placeholder.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def placeholder
  @placeholder
end

#requiredObject

Returns the value of attribute required.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def required
  @required
end

Returns the value of attribute result_link_class.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def result_link_class
  @result_link_class
end

Returns the value of attribute result_link_text.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def result_link_text
  @result_link_text
end

#search_urlObject

Returns the value of attribute search_url.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def search_url
  @search_url
end

#uid_dom_idObject

Returns the value of attribute uid_dom_id.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def uid_dom_id
  @uid_dom_id
end

#valueObject

Returns the value of attribute value.



6
7
8
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 6

def value
  @value
end

Instance Method Details

#htmlObject



13
14
15
16
17
18
19
20
21
22
23
24
# File 'app/helpers/ucb_rails/renderer/lps_typeahead_search_field.rb', line 13

def html
  (:div, class: 'control-group lps-typeahead') do
    label_html +
    (:div, class: 'controls') do
      (:div, class: 'input-append') do
        text_field_html +
        span_html
      end +
      (:p, hint, class: 'help-block')
    end
  end
end