Merge pull request #695 from warpc/add-invitation-link-to-register_requests-table

added invitation link to the table
This commit is contained in:
Vladimir Sharshov 2012-10-15 08:28:35 -07:00
commit c115a37a04
1 changed files with 8 additions and 3 deletions

View File

@ -24,9 +24,14 @@
%td= request.more
%td= request.created_at
%td
= link_to t("layout.approve"), approve_admin_register_request_path(request) if can? :approve, request
|
= link_to t("layout.reject"), reject_admin_register_request_path(request) if can? :reject, request
- links = []
- if can? :approve, request
- links << link_to(t("layout.approve"), approve_admin_register_request_path(request))
- if can? :reject, request
- links << link_to(t("layout.reject"), reject_admin_register_request_path(request))
- if request.token
- links << link_to('Link', new_user_registration_url(:invitation_token => request.token))
= raw links.join('|')
.actions
%input#approve_registration{:type => 'button', :value => "Approve Selected"}