+++ /dev/null
-<script>
- if (supportsHTML5Storage()) {
- var sonarRecentHistory = new Sonar.RecentHistory();
- }
-</script>
-
-<li>
- <a href="#" class="with-icon" onclick="if (sonarRecentHistory) { sonarRecentHistory.populateRecentHistoryPanel(); }; showDropdownMenu('projects-menu'); return false;">
- <span><%= message('layout.projects') -%></span>
- <i class="icon-dropdown"></i>
- </a>
-
- <div id="projects-menu" class="dropdown-menu" style="max-width: none; display: none;">
- <div id="recent-history" style="border-bottom: 1px solid #ccc; padding-bottom: 10px;">
- <h2><%= message('layout.recent_projects') -%></h2>
- <ul id="recent-history-list">
- </ul>
- </div>
-
- <div>
- <ul>
- <% Project.root_qualifiers.sort.each do |qualifier| %>
- <li><a href="<%= ApplicationController.root_context -%>/all_projects?qualifier=<%= qualifier -%>"><%= message('qualifiers.all.' + qualifier) -%></a></li>
- <% end %>
- </ul>
- </div>
- </div>
-
-</li>
-
-<script>
- if (sonarRecentHistory == null) {
- $j('#recent-history').detach();
- }
-
- <%
- if @resource && Project.root_qualifiers.include?(@resource.qualifier)
- %>
- else {
- sonarRecentHistory.add('<%= escape_javascript(h(@resource.key)) -%>',
- '<%= escape_javascript(h(@resource.name)) -%>',
- '<%= escape_javascript @resource.qualifier.downcase -%>');
- }
- <% end %>
-
-</script>
+++ /dev/null
-<li>
- <a href="#" onclick="showDropdownMenu('project-settings-menu'); return false;" class="link-more" id="project-settings-menu-link"><%= message('qualifier.configuration.' + @project.qualifier) -%></a>
-
- <div id="project-settings-menu" class="dropdown-menu" style="display: none">
- <% is_admin = has_role?(:admin, @project) %>
- <ul>
- <% if (is_admin && controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'configurable')) %>
- <li><a href="<%= ApplicationController.root_context -%>/project/settings/<%= @project.id -%>"><%= message('project_settings.page') -%></a></li>
- <% end %>
- <% if (@project.project?) %>
- <li><a href="<%= ApplicationController.root_context -%>/project/profile/<%= @project.id -%>"><%= message('project_quality_profiles.page') -%></a></li>
- <% end %>
- <% if (@project.project?) %>
- <li><a href="<%= ApplicationController.root_context -%>/project/qualitygate/<%= @project.id -%>"><%= message('project_quality_gate.page') -%></a></li>
- <% end %>
- <% if is_admin %>
- <li><a href="<%= ApplicationController.root_context -%>/manual_measures/index/<%= @project.id -%>"><%= message('manual_measures.page') -%></a></li>
- <% end %>
- <% if (is_admin && @project.project?) %>
- <li><a href="<%= ApplicationController.root_context -%>/action_plans/index/<%= @project.id -%>"><%= message('action_plans.page') -%></a></li>
- <% end %>
- <% if (is_admin && @project.project?) %>
- <li><a href="<%= ApplicationController.root_context -%>/project/links/<%= @project.id -%>"><%= message('project_links.page') -%></a></li>
- <% end %>
- <% if is_admin && controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'hasRolePolicy') %>
- <li><a href="<%= ApplicationController.root_context -%>/project_roles/index/<%= @project.id -%>"><%= message('permissions.page') -%></a></li>
- <% end %>
- <% if is_admin && controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'modifiable_history') %>
- <li><a href="<%= ApplicationController.root_context -%>/project/history/<%= @project.id -%>"><%= message('project_history.page') -%></a></li>
- <% end %>
- <% if is_admin && controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'updatable_key') %>
- <li><a href="<%= ApplicationController.root_context -%>/project/key/<%= @project.id -%>"><%= message('update_key.page') -%></a></li>
- <% end %>
- <% if is_admin && controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'deletable') %>
- <li><a href="<%= ApplicationController.root_context -%>/project/deletion/<%= @project.id -%>"><%= message('deletion.page') -%></a></li>
- <% end %>
- <% if is_admin
- controller.java_facade.getPages(Navigation::SECTION_RESOURCE_CONFIGURATION.key, @project.scope, @project.qualifier, @project.language, nil).each do |page|
- page_url = "#{page.getId()}?resource=#{@project.id}"
- %>
- <li><a href="<%= ApplicationController.root_context -%><%= page_url -%>"><%= h message(page.getId() + '.page', :default => page.getTitle()) -%></a></li>
- <% end
- end %>
- </ul>
- </div>
-
-</li>
+++ /dev/null
-<li>
- <a href="#" class="with-icon" onclick="showDropdownMenu('user-panel'); return false;">
- <span><%= h current_user.name -%></span>
- <i class="icon-dropdown"></i>
- </a>
-
-
- <div id="user-panel" class="dropdown-menu" style="display: none">
- <ul>
- <li><a href="<%= ApplicationController.root_context -%>/account/index"><%= message('layout.user_panel.my_profile') -%></a></li>
- <li><a href="<%= ApplicationController.root_context -%>/sessions/logout" onclick="if (sonarRecentHistory) { sonarRecentHistory.clear(); }"><%= message('layout.logout') -%></a></li>
- </ul>
- </div>
-
-</li>