ajout d'une route /manager/users/:id/emails
This commit is contained in:
parent
e9c33ecbd0
commit
27b8797296
4 changed files with 27 additions and 0 deletions
|
@ -46,5 +46,10 @@ module Manager
|
|||
|
||||
redirect_to manager_users_path
|
||||
end
|
||||
|
||||
def emails
|
||||
@user = User.find(params[:id])
|
||||
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -1,3 +1,11 @@
|
|||
<dl>
|
||||
<dt class="attribute-label" id="meta-usager">
|
||||
Emails
|
||||
</dt>
|
||||
<dd class="attribute-data attribute-data--meta-usager">
|
||||
<%= link_to('Voir les derniers emails', emails_manager_user_path(user)) %>
|
||||
</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt class="attribute-label" id="meta-usager">
|
||||
Usager
|
||||
|
|
13
app/views/manager/users/emails.html.erb
Normal file
13
app/views/manager/users/emails.html.erb
Normal file
|
@ -0,0 +1,13 @@
|
|||
<% content_for(:title) { "Emails vers #{@user.email}" } %>
|
||||
|
||||
<header class="main-content__header" role="banner">
|
||||
<h1 class="main-content__page-title">
|
||||
<%= content_for(:title) %>
|
||||
</h1>
|
||||
</header>
|
||||
|
||||
<section class="main-content__body">
|
||||
<dl>
|
||||
|
||||
</dl>
|
||||
</section>
|
|
@ -31,6 +31,7 @@ Rails.application.routes.draw do
|
|||
delete 'delete', on: :member
|
||||
post 'resend_confirmation_instructions', on: :member
|
||||
put 'enable_feature', on: :member
|
||||
get 'emails', on: :member
|
||||
end
|
||||
|
||||
resources :instructeurs, only: [:index, :show] do
|
||||
|
|
Loading…
Reference in a new issue