Module: BouncyBots::FormBuilderExt

Defined in:
lib/bouncy_bots/form_builder_ext.rb

Instance Method Summary collapse

Instance Method Details

#bounce_field(options = {}) ⇒ Object



3
4
5
# File 'lib/bouncy_bots/form_builder_ext.rb', line 3

def bounce_field(options = {})
  ActionView::Helpers::InstanceTag.new(object_name, @template.controller.bounce_field, self, options.delete(:object)).to_input_field_tag("text", options)
end

#bounce_label(text = nil, options = {}) ⇒ Object



7
8
9
# File 'lib/bouncy_bots/form_builder_ext.rb', line 7

def bounce_label(text = nil, options = {})
  ActionView::Helpers::InstanceTag.new(object_name, @template.controller.bounce_field, self, options.delete(:object)).to_label_tag(text, options)
end