Class: AnyView::Helpers::FormBuilder::StandardFormBuilder

Inherits:
AbstractFormBuilder show all
Defined in:
lib/any_view/form_builder/standard_form_builder.rb

Instance Attribute Summary

Attributes inherited from AbstractFormBuilder

#object, #view_context

Instance Method Summary collapse

Methods inherited from AbstractFormBuilder

#check_box, #error_messages, #file_field, #hidden_field, #image_submit, #initialize, #label, #password_field, #radio_button, #select, #submit, #text_area, #text_field

Constructor Details

This class inherits a constructor from AnyView::Helpers::FormBuilder::AbstractFormBuilder

Instance Method Details

#image_submit_block(source, options = {}) ⇒ Object

image_submit_block(“submit.png”)


30
31
32
33
# File 'lib/any_view/form_builder/standard_form_builder.rb', line 30

def image_submit_block(source, options={})
  submit_html = self.image_submit(source, options)
  @view_context.(:p, submit_html)
end

#submit_block(caption, options = {}) ⇒ Object

submit_block(“Update”)


24
25
26
27
# File 'lib/any_view/form_builder/standard_form_builder.rb', line 24

def submit_block(caption, options={})
  submit_html = self.submit(caption, options)
  @view_context.(:p, submit_html)
end