Skip to content

Commit 500ad23

Browse files
committed
Show inactive label on user roster page
Fixes CNVS-28046 Test plan: - Create a user - Enroll the user in a course - On the "people" tab, click on the user's name - Click "more user details..." - Ensure that neither "inactive" nor "completed" appear below the "created ..." line - Go back to the "people" tab - Click the cog menu next to the user's name, then click "deactivate" and click "ok" in the resulting prompt - Click on the user's name - Click "more user details..." - Ensure that "inactive" appears below the "created ..." line - Click "conclude this enrollment" - Ensure that "concluded" appears below the "created ..." line Change-Id: I5ea34ce30aa2e88bf5de72e3155f988eb27f708d Reviewed-on: https://gerrit.instructure.com/74599 Tested-by: Jenkins Reviewed-by: Jeremy Stanley <jeremy@instructure.com> QA-Review: August Thornton <august@instructure.com> Product-Review: Alex Boyd <aboyd@instructure.com>
1 parent b730719 commit 500ad23

1 file changed

Lines changed: 9 additions & 1 deletion

File tree

app/views/context/roster_user.html.erb

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,15 @@
107107
:wrapper => '<span class="associated_user_name">\1</span>' %>
108108
</div>
109109
<% end %>
110-
<div style="font-size: 0.8em; padding-left: 20px; <%= hidden unless enrollment.completed? %>" class="completed_at_holder"><%= t 'completed_enrollment', "completed *%{completed_at}*", :completed_at => datetime_string(enrollment.completed_at), :wrapper => '<span class="completed_at">\1</span>' %></div>
110+
<div style="font-size: 0.8em; padding-left: 20px; <%= hidden unless enrollment.completed? || enrollment.inactive? %>" class="completed_at_holder">
111+
<% if enrollment.inactive? %>
112+
<%= t 'inactive' %>
113+
<% elsif enrollment.completed_at %>
114+
<%= t 'completed_enrollment', "completed *%{completed_at}*", :completed_at => datetime_string(enrollment.completed_at), :wrapper => '<span class="completed_at">\1</span>' %>
115+
<% else %>
116+
<%= t 'completed' %>
117+
<% end %>
118+
</div>
111119
</td>
112120
<% if enrollment.admin? ? (can_manage_admins && enrollment.user_id != @current_user.id) : can_manage_students %>
113121
<td style="vertical-align: top; padding: 5px; font-size: 0.8em;">

0 commit comments

Comments
 (0)