app/views/admin/admin_users/index.haml
- content_for :actions do
= link_to(t('.new_btn'), new_admin_admin_user_path, class: 'btn btn-primary')
= render 'shared/title', name: t('.title')
= render 'application/pagination'
.row
.col-md-12
.table-responsive
%table.table.table-hover.table-bordered.table-condensed
%thead
%tr
%th{class: 'col-xs-2'}
= sort_link(@q, 'username')
%th{class: 'col-xs-2'}
= sort_link(@q, 'email', t(:email))
%th{class: 'col-xs-2'}
= sort_link(@q, 'identity_code', t(:identity_code))
%th{class: 'col-xs-2'}
= sort_link(@q, 'role', t(:role))
%tbody
- @admin_users.each do |x|
%tr
%td= link_to(x, [:admin, x])
%td= x.email
%td= x.identity_code
- if x.roles
%td= x.roles.first
- else
%td
.row
.col-md-6
= paginate @admin_users
.col-md-6.text-right
= t(:result_count, count: @count)