]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-3972 Move the "Add to favorite" star into the breadcrumbs bar
authorFabrice Bellingard <fabrice.bellingard@sonarsource.com>
Mon, 3 Dec 2012 15:35:28 +0000 (16:35 +0100)
committerFabrice Bellingard <fabrice.bellingard@sonarsource.com>
Tue, 4 Dec 2012 14:35:01 +0000 (15:35 +0100)
sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_header.html.erb
sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_breadcrumb.html.erb
sonar-server/src/main/webapp/stylesheets/layout.css

index 474bf68a477827ffcc1988720593c21f905b3044..c23bf7917d45b237f2ebd20542c77c974b9b118b 100644 (file)
@@ -13,7 +13,7 @@
   <% if @snapshot %>
     <div id="snapshot_title" class="page_title">
       <h4>
-        <%= link_to_favourite(@project) -%> <%= "Version #{@snapshot.version} - " if @snapshot.version.present? -%><%= l @snapshot.created_at -%>
+        <%= "Version #{@snapshot.version} - " if @snapshot.version.present? -%><%= l @snapshot.created_at -%>
         <% if @snapshot.project_snapshot.periods? %>
           <form method="GET" action="<%= url_for :controller => :dashboard, :action => :index, :id => @resource.id -%>" style="display: inline" class="spacer-left">
             <input type="hidden" name="did" value="<%= @dashboard.id -%>"/>
index 8a653b42cc139fff8b3cdfe8f1972929f7c4d978..bd1ffc42a10685d9340754cc8d50e3c3893134c7 100644 (file)
@@ -1,13 +1,18 @@
 <% if @breadcrumbs %>
 
   <div id="crumbs">
-    <% if @permalink %>
-      <ul id="crumbs-ops">
+    <ul id="crumbs-ops">
+      <% if @resource %>
+        <li>
+          <%= link_to_favourite(@resource) -%>
+        </li>
+      <% end %>
+      <% if @permalink %>
         <li>
           <a href="<%= @permalink -%>"><img src="<%= ApplicationController.root_context -%>/images/permalink.png" width="16" height="16" title="<%= message('permalink') -%>"/></a>
         </li>
-      </ul>
-    <% end %>
+      <% end %>
+    </ul>
     <ul id="bc">
       <%
          @breadcrumbs.each do |breadcrumb|
 %>
 
   <div id="crumbs">
-    <% if !@review %>
-      <ul id="crumbs-ops">
+    <ul id="crumbs-ops">
+      <% if @resource %>
+        <li>
+          <%= link_to_favourite(@resource) -%>
+        </li>
+      <% end %>
+      <% if !@review %>
         <li>
           <a href="<%= url_for(:overwrite_params => {:id => displayed_resource.key}) -%>"><img src="<%= ApplicationController.root_context -%>/images/permalink.png" width="16" height="16" title="<%= message('permalink') -%>"/></a>
         </li>
-      </ul>
-    <% end %>
+      <% end %>
+    </ul>
     <ul id="bc">
       <%
          resource_link = {}
index 1f6f21b27ed34fca333b596edceabb44cec2d0eb..880ea3eb43ee9c13d5ee56fa51576e53163c29c6 100644 (file)
@@ -143,6 +143,11 @@ body, a {
   padding: 0 5px 0 0;
 }
 
+#crumbs-ops li {
+  float: left;
+  padding: 0 0 0 10px;
+}
+
 #content {
   padding: 10px;
 }