adds user menu

This commit is contained in:
rgarcia
2015-07-17 19:47:19 +02:00
parent 3ee102c0c5
commit 30982d101f
2 changed files with 12 additions and 0 deletions

View File

@@ -0,0 +1,9 @@
<% if user_signed_in? %>
<li>
<%= link_to('Logout', destroy_user_session_path, :method => :delete) %>
</li>
<% else %>
<li>
<%= link_to('Login', new_user_session_path) %>
</li>
<% end %>

View File

@@ -14,6 +14,9 @@
<body style="margin-left:50px"> <body style="margin-left:50px">
<p class="alert"><%= notice %></p> <p class="alert"><%= notice %></p>
<p class="alert"><%= alert %></p> <p class="alert"><%= alert %></p>
<%= render 'devise/menu/login_items' %>
<%= yield %> <%= yield %>
</body> </body>
</html> </html>