Module: BootstrapBuilder::Helper
- Defined in:
- lib/bootstrap_builder/helper.rb
Instance Method Summary collapse
Instance Method Details
#bootstrap_form_for(record_or_name_or_array, *args, &proc) ⇒ Object
3 4 5 6 7 8 9 10 11 12 |
# File 'lib/bootstrap_builder/helper.rb', line 3 def bootstrap_form_for(record_or_name_or_array, *args, &proc) = args. .merge!(:builder => BootstrapBuilder::Builder) [:html] ||= { } [:html][:class] ||= '' if !([:html][:class] =~ /form-/) [:html][:class] += ' ' + BootstrapBuilder.config.default_form_class end form_for(record_or_name_or_array, *(args << ), &proc) end |