Aggiedit/lib/aggiedit_web/templates/layout/_user_menu.html.heex
2022-04-14 11:43:34 -06:00

15 lines
609 B
Plaintext

<%= if @current_user do %>
<li class="nav-item active">
<%= link "#{@current_user.username}/settings", to: Routes.user_settings_path(@conn, :edit), class: "nav-link" %>
</li>
<li class="nav-item active">
<%= link "Log out", to: Routes.user_session_path(@conn, :delete), method: :delete, class: "nav-link" %>
</li>
<% else %>
<li class="nav-item active">
<%= link "Register", to: Routes.user_registration_path(@conn, :new), class: "nav-link" %>
</li>
<li class="nav-item active">
<%= link "Log in", to: Routes.user_session_path(@conn, :new), class: "nav-link" %>
</li>
<% end %>