2017-11-27 07:07:59 -08:00
|
|
|
- content_for :page_title do
|
|
|
|
= t('admin.invites.title')
|
|
|
|
|
2017-12-01 07:40:02 -08:00
|
|
|
.filters
|
|
|
|
.filter-subset
|
|
|
|
%strong= t('admin.invites.filter.title')
|
|
|
|
%ul
|
|
|
|
%li= filter_link_to t('admin.invites.filter.all'), available: nil, expired: nil
|
|
|
|
%li= filter_link_to t('admin.invites.filter.available'), available: 1, expired: nil
|
|
|
|
%li= filter_link_to t('admin.invites.filter.expired'), available: nil, expired: 1
|
|
|
|
|
2018-08-18 15:58:53 -07:00
|
|
|
%hr.spacer/
|
|
|
|
|
2017-11-27 07:07:59 -08:00
|
|
|
- if policy(:invite).create?
|
|
|
|
%p= t('invites.prompt')
|
|
|
|
|
2023-09-28 06:40:28 -07:00
|
|
|
= simple_form_for(@invite, url: admin_invites_path) do |form|
|
|
|
|
= render partial: 'invites/form', object: form
|
2017-11-27 07:07:59 -08:00
|
|
|
|
2018-08-18 15:58:53 -07:00
|
|
|
%hr.spacer/
|
2017-11-27 07:07:59 -08:00
|
|
|
|
2019-03-13 21:25:49 -07:00
|
|
|
.table-wrapper.simple_form
|
|
|
|
%table.table.table--invites
|
2018-08-18 15:58:53 -07:00
|
|
|
%thead
|
|
|
|
%tr
|
2019-03-13 21:25:49 -07:00
|
|
|
%th
|
2018-08-18 15:58:53 -07:00
|
|
|
%th
|
|
|
|
%th= t('invites.table.uses')
|
|
|
|
%th= t('invites.table.expires_at')
|
|
|
|
%th
|
|
|
|
%tbody
|
|
|
|
= render @invites
|
2017-11-27 07:07:59 -08:00
|
|
|
|
|
|
|
= paginate @invites
|
2018-08-18 15:58:53 -07:00
|
|
|
|
|
|
|
- if policy(:invite).deactivate_all?
|
|
|
|
= link_to t('admin.invites.deactivate_all'), deactivate_all_admin_invites_path, method: :post, data: { confirm: t('admin.accounts.are_you_sure') }, class: 'button'
|