education/classroom

View on GitHub
app/views/assignments/_assignment_roster_list.html.erb

Summary

Maintainability
Test Coverage
<% if list_type == :roster_entries && roster_entries.present? %>
  <% roster_entries.each do |entry| %>
    <%= render partial: 'orgs/assignment_repos/assignment_repo', locals: {
      url: organization_assignment_roster_entry_path(organization, assignment, entry)
    } %>
  <% end %>
<% elsif list_type == :assignment_repos && assignment_repos.present? %>
  <% assignment_repos.each do |assignment_repo| %>
    <%= render partial: 'orgs/assignment_repos/assignment_repo', locals: {
      url: organization_assignment_assignment_repo_path(organization, assignment, assignment_repo)
    } %>
  <% end %>
<% else %>
  <div class="blankslate">
    <h3>"<%= assignment.title %>" does not have any repositories matching this query</h3>
  </div>
<% end %>