skill-assessment-app/app/views/admin/candidate/index.html.erb

41 lines
1.4 KiB
Plaintext
Raw Normal View History

2016-09-22 16:29:19 -05:00
<%
content_for :section_title, "Candidates"
2016-11-22 16:59:54 -06:00
content_for :title, "Candidates - Skills Assessment Admin"
2016-09-22 16:29:19 -05:00
%>
2016-07-31 09:56:02 -05:00
2017-03-20 14:38:57 -05:00
<h1>Candidates</h1>
2017-03-20 10:57:50 -05:00
<%= link_to("Create New Candidate", admin_new_candidate_path, { class: "" }) if policy(Candidate).create? %>
<table cellspacing="0" cellpadding="0">
<tr>
<th><%= sortable "name", "Candidate" %></th>
<th><%= sortable "test_hash", "Test ID" %></th>
<th><%= sortable "email" %></th>
<th><%= sortable "experience" %></th>
<th>Progress</th>
<th><%= sortable "completed_at", "Completed" %></th>
<th><%= sortable "reminded" %></th>
<th>Interview?</th>
</tr>
<% @candidates.each do |candidate| %>
2016-07-31 09:56:02 -05:00
<tr>
2017-03-20 10:57:50 -05:00
<td><%= link_to candidate.name, admin_edit_candidate_path(candidate.id) %></td>
<td><%= candidate.test_hash %></td>
<td>
<%= mail_to(candidate.email) %>
<br />
<%= link_to "resend welcome email", admin_resend_welcome_path(candidate.id), remote: true, class: '', data: { id: 'ajax-action' } %>
</td>
<td><%= candidate.experience %> years</td>
<td><%= candidate.status %></td>
<td><%= candidate.completed ? link_to("Submitted", admin_result_path(candidate.test_hash)) : "" %></td>
2017-05-01 16:17:41 -05:00
<td><%= raw candidate.reminded ? "&check;" : "&middot;" %></td>
2017-03-20 10:57:50 -05:00
<td><%= candidate.interview? %></td>
2016-07-31 09:56:02 -05:00
</tr>
2017-03-20 10:57:50 -05:00
<% end %>
</table>
2016-07-31 09:56:02 -05:00
2017-03-20 10:57:50 -05:00
<%= paginate @candidates %>