Edit Employment

<%= form_with(model: @employment, url: employment_path(@employment), method: :patch, local: true, html: { class: 'needs-validation', novalidate: true }) do |form| %> <% if @employment.errors.any? %> <% end %>
<%= form.label :start_date, class: 'form-label' %> <%= form.date_field :start_date, class: 'form-control' %>
<%= form.label :end_date, class: 'form-label' %> <%= form.date_field :end_date, class: 'form-control' %>
<%= form.submit "Update Employment", class: 'btn btn-dark' %>
<% end %>
<%= link_to 'Back to Participant', participant_path(@employment.participant), class: 'btn btn-secondary' %> <%= link_to 'Delete Employment', employment_path(@employment), method: :delete, data: { confirm: 'Are you sure?' }, class: 'btn btn-danger' %>