Module: Bh::Form::SubmitHelper

Includes:
BaseHelper
Included in:
Bh::FormBuilder
Defined in:
lib/bh/helpers/form/submit_helper.rb

Instance Method Summary collapse

Methods included from GlyphiconHelper

#glyphicon

Instance Method Details

#submit(value = nil, options = {}) ⇒ Object



8
9
10
11
12
13
14
15
16
17
18
19
20
# File 'lib/bh/helpers/form/submit_helper.rb', line 8

def submit(value=nil, options={})
  context = options.delete(:context) || 'primary'
  append_class! options, "btn btn-#{context}"
  if horizontal_form?
     :div, class: 'form-group' do
       :div, class: 'col-sm-offset-3 col-sm-9' do
        super value, options
      end
    end
  else
    super value, options
  end
end