app/views/sweeps/_form.html.haml
= form_for [@project, @sweep], html: { role: 'form' } do |f|
= render 'shared/error_explanation', instance: @sweep
.form-group
= f.label :title, class: 'control-label'
= f.text_field :title, class: 'form-control',
autofocus: true, required: true
.form-group
= f.label :description, class: 'control-label'
= f.text_area :description, rows: 4, class: 'form-control'
.form-group
= f.label :email, class: 'control-label'
= f.text_field :email, class: 'form-control', type: 'email'
%p.help-block= t('.email_help')
.form-group
= f.label :delay_seconds, class: 'control-label'
= f.text_field :delay_seconds, class: 'form-control', type: 'number',
min: '1', step: '1', pattern: '\d+'
%p.help-block= t('.delay_seconds_help')
.form-group
= f.submit class: 'btn btn-primary'