Sha256: 9e205e95470cc06a103c72f54743dcc17bf4590ce2f46447753191f04c1499e7

Contents?: true

Size: 1.89 KB

Versions: 4

Compression:

Stored size: 1.89 KB

Contents

<div id="user-util-links">

  <% if current_user %>

      <div id="user-nav-btn" class="btn-group">
        <%= "#{ link_to content_tag(:span, '', :class => 'glyphicon glyphicon-user') + ' ' + current_user.first_name,
                        current_user, :class =>'btn btn-default btn-xs' }".html_safe unless current_user.to_s.blank? %>
        <button class="btn btn-default dropdown-toggle btn-xs hidden-xs" data-toggle="dropdown">
          <span class="caret"></span>
        </button>
        <ul id="user-util-links-list" class="dropdown-menu">
          <li><%= link_to t('blacklight.header_links.folders'), folders_path %></li>
          <li><%= link_to t('blacklight.header_links.saved_searches'), blacklight.saved_searches_path %></li>
          <li><%= link_to t('blacklight.header_links.search_history'), blacklight.search_history_path %></li>
          <li><%= link_to t('devise.registrations.edit'), edit_user_registration_path %></li>
          <li><%= link_to t('blacklight.header_links.logout'), destroy_user_session_path %></li>
        </ul>
      </div>

  <% else %>
      <div id="util-links-nologin">
      <ul id="user-util-links-list" class="list-inline">
        <% unless @searches.blank? && session[:history].blank? %>
            <% if current_or_guest_user %>
                <li><%= link_to t('blacklight.header_links.folders'), folders_path %></li>
            <% end %>
            <!-- <li><%# link_to t('blacklight.header_links.search_history'), search_history_path %></li> -->
        <% end %>
        <% if has_user_authentication_provider? %>
            <li><%= link_to t('blacklight.header_links.login'), new_user_session_path %></li>
        <% end %>
      </ul>
      </div>

  <% end %>

  <% unless params[:controller] == 'pages' && params[:action] == 'home' %>
      <div id="header-search">
        <%= render :partial=>'shared/search_form_header'  %>
      </div>
  <% end %>

</div>

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
commonwealth-vlr-engine-0.0.7 app/views/shared/_user_util_links.html.erb
commonwealth-vlr-engine-0.0.4 app/views/shared/_user_util_links.html.erb
commonwealth-vlr-engine-0.0.3 app/views/shared/_user_util_links.html.erb
commonwealth-vlr-engine-0.0.2 app/views/shared/_user_util_links.html.erb