<%= admin_breadcrumbs(@breadcrumbs) %>

Teachers

<%= link_to "New Teacher", new_admin_teacher_path, class: "inline-flex items-center px-4 py-2 border border-transparent shadow-sm text-sm font-medium rounded-md text-white bg-blue-600 hover:bg-blue-700" %>
<% current_filter = current_discard_filter %>
<%= link_to "Active", admin_teachers_path, class: "px-4 py-2 text-sm font-medium #{current_filter == :active ? 'text-blue-600 border-b-2 border-blue-600' : 'text-gray-500 hover:text-gray-700 hover:border-gray-300'}" %> <%= link_to "Deactivated", admin_teachers_path(discarded: true), class: "px-4 py-2 text-sm font-medium #{current_filter == :discarded ? 'text-blue-600 border-b-2 border-blue-600' : 'text-gray-500 hover:text-gray-700 hover:border-gray-300'}" %> <%= link_to "All", admin_teachers_path(all: true), class: "px-4 py-2 text-sm font-medium #{current_filter == :all ? 'text-blue-600 border-b-2 border-blue-600' : 'text-gray-500 hover:text-gray-700 hover:border-gray-300'}" %>
<% if @teachers.any? %> <% @teachers.each do |teacher| %> <% end %> <% else %> <% end %>
<%= sort_link(:id, "ID") %> <%= sort_link(:username, "Username") %> <%= sort_link(:email, "Email") %> <%= sort_link(:name, "Name") %> <%= sort_link(:created_at, "Created At") %> Status Actions
<%= teacher.id %> <%= teacher.username %> <%= teacher.email %> <%= teacher.name %> <%= teacher.created_at.strftime("%B %d, %Y") %> <% if teacher.discarded? %> Deactivated <% else %> Active <% end %>
<%= link_to "View", admin_teacher_path(teacher), class: "text-blue-600 hover:text-blue-800" %> <%= link_to "Edit", edit_admin_teacher_path(teacher), class: "text-gray-600 hover:text-gray-800" %> <% if teacher.discarded? %> <%= link_to "Reactivate", admin_teacher_reactivation_path(teacher), data: { turbo_method: :post, turbo_confirm: "Are you sure you want to reactivate this teacher?" }, class: "text-green-600 hover:text-green-800" %> <% else %> <%= link_to "Deactivate", admin_teacher_deactivation_path(teacher), data: { turbo_method: :post, turbo_confirm: "Are you sure you want to deactivate this teacher?" }, class: "text-red-600 hover:text-red-800" %> <% end %>

No records found

No teachers found. Create your first teacher to get started.