aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJulien Lancelot <julien.lancelot@gmail.com>2013-02-20 18:22:21 +0100
committerJulien Lancelot <julien.lancelot@gmail.com>2013-02-20 18:22:21 +0100
commit3e1455a524eaecf77dd771acf72eb5393ef8d298 (patch)
tree3f7412c658273964b64709b150e2e365dbac6297
parentdd8e6540a7e1cab420488489c326b5c5d02016d4 (diff)
downloadsonarqube-3e1455a524eaecf77dd771acf72eb5393ef8d298.tar.gz
sonarqube-3e1455a524eaecf77dd771acf72eb5393ef8d298.zip
SONAR-2227 Display dependencies as plugins include
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/available.html.erb11
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/updates.html.erb15
2 files changed, 19 insertions, 7 deletions
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/available.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/available.html.erb
index 000736a63d7..9f0eca65f7b 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/available.html.erb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/available.html.erb
@@ -42,6 +42,7 @@ function installPlugin(key) {
<%= plugin.getDescription() %>
<div id="detail-<%= plugin.getKey() -%>" style="display:none">
<table class="spaced width100">
+
<% index = 0 %>
<% plugin.lastRelease.children.each do |child|
child_plugin = @update_center_referential.findPlugin(child.key)
@@ -58,10 +59,14 @@ function installPlugin(key) {
<% end %>
<% release = @update_plugin_center.findLatestCompatibleRelease(plugin.key) %>
- <% release_dep_names = release.outgoingDependencies.collect { |dep| dep.artifact.name } %>
- <% unless release_dep_names.empty? %>
+ <% release.outgoingDependencies.each_with_index do |outgoing_release, index| %>
<tr>
- <td class="thin nowrap" colspan="2"><b>Installing this plugin will also install: </b><%= release_dep_names.join(', ') -%></td>
+ <% if index == 0 %>
+ <td class="thin nowrap"><b>Installing this plugin will also install:</b></td>
+ <% else %>
+ <td>&nbsp;</td>
+ <% end %>
+ <td><span><%= outgoing_release.artifact.name -%></span> : <span><%= @update_center_referential.findPlugin(outgoing_release.key).description -%></span></td>
</tr>
<% end %>
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/updates.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/updates.html.erb
index 2095f0e0141..99f6e3c6954 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/updates.html.erb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/views/updatecenter/updates.html.erb
@@ -53,12 +53,19 @@ function upgradePlugin(key) {
<% release = @update_plugin_center.findLatestCompatibleRelease(plugin.key)
releases = release.outgoingDependencies + release.incomingDependencies
- release_dep_names = releases.collect { |dep| dep.artifact.name } %>
- <% unless release_dep_names.empty? %>
- <tr>
+ %>
+ <% releases.each_with_index do |dep_release, index| %>
+ <tr class="<%= css -%>">
<td> </td>
<td> </td>
- <td class="thin nowrap" colspan="5"><b>Updating this plugin will also update: </b><%= release_dep_names.join(', ') -%></td>
+ <% if index == 0 %>
+ <td class="thin nowrap"><b>Updating this plugin will also update:</b></td>
+ <% else %>
+ <td >&nbsp;</td>
+ <% end %>
+ <td colspan="4">
+ <span><%= dep_release.artifact.name -%></span> : <span><%= @update_center_referential.findPlugin(dep_release.key).description -%></span>
+ </td>
</tr>
<% end %>