rubyforgood/babywearing

View on GitHub
app/views/users/registrations/_form_fields.html.erb

Summary

Maintainability
Test Coverage
<div class="form-group">
  <%= f.text_field :first_name,
                   required: true,
                   class: 'form-control form-control-user',
                   aria: { 'label': 'first_name' },
                   placeholder: 'First name'
  %>
</div>

<div class="form-group">
  <%= f.text_field :last_name,
                   required: true,
                   class: 'form-control form-control-user',
                   aria: { 'label': 'last_name' },
                   placeholder: 'Last name'
  %>
</div>
<div class="form-group">
  <%= f.text_field :street_address,
                   required: true,
                   class: 'form-control form-control-user',
                   aria: { 'label': 'street_address' },
                   placeholder: 'Street address'
  %>
</div>

<div class="form-group">
  <%= f.text_field :street_address_second,
                   class: 'form-control form-control-user',
                   aria: { 'label': 'Apt, Suite, Floor, etc.' },
                   placeholder: 'Apt, Suite, Floor, etc.'
  %>
</div>

<div class="form-group">
  <%= f.text_field :city,
                   required: true,
                   class: 'form-control form-control-user',
                   aria: { 'label': 'City' },
                   placeholder: 'City'
  %>
</div>

<div class="form-group">
  <%= f.text_field :state,
                   required: true,
                   class: 'form-control form-control-user',
                   aria: { 'label': 'State' },
                   placeholder: 'State'
  %>
</div>

<div class="form-group">
  <%= f.text_field :postal_code,
                   required: true,
                   class: 'form-control form-control-user',
                   aria: { 'label': 'Postal code' },
                   placeholder: 'Postal code'
  %>
</div>

<div class="form-group">
  <%= f.phone_field :phone_number,
                   required: true,
                   class: 'form-control form-control-user',
                   aria: { 'label': 'Phone' },
                   placeholder: 'Phone',
                   value: number_to_phone(f.object.phone_number)
  %>
</div>