]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-3471 Add a link to "My Filters" when editing a Filter widget
authorDavid Gageot <david@gageot.net>
Thu, 17 May 2012 16:50:35 +0000 (18:50 +0200)
committerDavid Gageot <david@gageot.net>
Fri, 18 May 2012 06:57:40 +0000 (08:57 +0200)
plugins/sonar-l10n-en-plugin/src/main/resources/org/sonar/l10n/core.properties
sonar-server/src/main/webapp/WEB-INF/app/views/dashboard/_widget_properties.html.erb

index 8ba9903db9ff0b9f5f080143b4bd6a5c8f2b452b..6a2c59d61b29dfbd23a37a014bb5a7e4f7643ece 100644 (file)
@@ -772,6 +772,7 @@ widget.image.description=Shows an image with a link
 
 widget.filter.name=Filter
 widget.filter.description=Shows a pre-configured filter
+widget.filter.edit=Edit my filters
 
 widget.resource_id=Project
 
index 41288c9f52bc92c4fa249302f819c1f1c65f2f5a..fca835f2d4eab351549fe4348df878fb6735402e 100644 (file)
 
     <% widget.java_definition.getWidgetProperties().sort { |w1, w2| natural_comparison(w1.key, w2.key) }.each do |property_def| %>
       <tr>
-        <td class="form-key-cell"><%= property_def.key() -%><%= "*" unless property_def.optional()==true -%></td>
+        <td class="form-key-cell"><%= property_def.key() -%><%= "*" unless property_def.optional() -%></td>
         <td class="form-val-cell" id="row_<%= property_def.key() -%>">
           <%= property_value_field(property_def, widget.property_text_value(property_def.key())) -%>
+          <% if property_def.key() == 'filter' %>
+            <%= link_to message('widget.filter.edit'), {:controller => :filters, :action => :manage}, :class => 'link-action' %>
+          <% end %>
           <div class="form-val-note">
             <%= message("widget." + widget.key + ".param." + property_def.key(), :default => property_def.description()) -%>
           </div>