Module: Lipsiadmin::View::Helpers::FormTagHelper
- Defined in:
- lib/view/helpers/view_helper.rb
Overview
Returns text_area_tag, text_field_tag, password_field_tag with a default extjs css style.
Class Method Summary collapse
-
.included(base) ⇒ Object
:nodoc:.
Instance Method Summary collapse
-
#password_field_tag_with_style(name, value = nil, options = {}) ⇒ Object
Returns password_field_tag with extjs style alias for password_field_tag, for use the original tag use:.
-
#text_area_tag_with_style(name, value = nil, options = {}) ⇒ Object
Returns text_area_tag with extjs style alias for text_area_tag, for use the original tag use:.
-
#text_field_tag_with_style(name, value = nil, options = {}) ⇒ Object
Returns text_field_tag with extjs style alias for text_field_tag, for use the original tag use:.
Class Method Details
.included(base) ⇒ Object
:nodoc:
55 56 57 58 59 |
# File 'lib/view/helpers/view_helper.rb', line 55 def self.included(base)#:nodoc: base.alias_method_chain :text_field_tag, :style base.alias_method_chain :text_area_tag, :style base.alias_method_chain :password_field_tag, :style end |
Instance Method Details
#password_field_tag_with_style(name, value = nil, options = {}) ⇒ Object
Returns password_field_tag with extjs style alias for password_field_tag, for use the original tag use:
password_field_tag_style
88 89 90 91 92 |
# File 'lib/view/helpers/view_helper.rb', line 88 def password_field_tag_with_style(name, value = nil, = {}) [:class] ||= "x-form-text" [:style] ||= "width:100%" password_field_tag_without_style(name, value, ) end |
#text_area_tag_with_style(name, value = nil, options = {}) ⇒ Object
Returns text_area_tag with extjs style alias for text_area_tag, for use the original tag use:
text_area_tag_without_style
66 67 68 69 70 |
# File 'lib/view/helpers/view_helper.rb', line 66 def text_area_tag_with_style(name, value = nil, = {}) [:class] ||= "x-form-field" [:style] ||= "width:100%;height:80px" text_area_tag_without_style(name, value, ) end |
#text_field_tag_with_style(name, value = nil, options = {}) ⇒ Object
Returns text_field_tag with extjs style alias for text_field_tag, for use the original tag use:
text_field_tag_without_style
77 78 79 80 81 |
# File 'lib/view/helpers/view_helper.rb', line 77 def text_field_tag_with_style(name, value = nil, = {}) [:class] ||= "x-form-text" [:style] ||= "width:100%" text_field_tag_without_style(name, value, ) end |