osem-fcy/app/views/admin/invites/index.html.haml
Rahul 1c04e820b8 add invites actions in controller and views
Index is added so organizer can see who they have invited. Oganizers will now be able to invite users with their email.Organizer will be able to delete and edit a invite.Add test for actions.
2019-10-25 13:28:03 +05:30

42 lines
1.1 KiB
Text

.row
.col-md-12
.page-header
%h1
Invitations
.row
.col-md-12
- if @invites.present?
%table.datatable
%thead
%th
%b ID
%th
%b User
%th
%b Invited for
%th
%b Invitation validity
%th
%b Action
- @invites.each do |invite|
%tr
%td
= invite.id
%td
= invite.emails
%td
= invite.invite_for
%td
= invite.end_date
%td
= link_to 'Edit', edit_admin_conference_invite_path(@conference.short_title, invite.id),
class: 'btn btn-primary'
= link_to 'Delete', admin_conference_invite_path(@conference.short_title, invite.id), method: :delete,
data: { confirm: 'Are you sure?' }, class: 'btn btn-danger'
.row
.col-md-12.text-right
- if can? :create, Invite
= link_to 'Late Submission Invite', new_admin_conference_invite_path(@conference.short_title), class: 'button btn btn-success'