Bug 8282: Bug in modules list in about.pl

Last modules were not displayed if the number of modules did not match the number of rows of the table (when $number_of_modules % 4 != 0)

Signed-off-by: Marc Veron <veron@veron.ch>

Added some code to about.tt to have empty the last remaining cells, not sure if an other signoff is needed.

Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
(cherry picked from commit 7d237f22ad)
This commit is contained in:
Matthias Meusburger 2012-06-21 15:41:54 +02:00 committed by Jared Camins-Esakov
parent 645783c253
commit 6b1ca78dd3
2 changed files with 17 additions and 3 deletions

View File

@ -108,6 +108,13 @@ foreach (@components) {
$row = [];
}
}
# Processing the last line (if there are any modules left)
if (scalar(@$row) > 0) {
# Extending $row to the table size
$$row[3] = '';
# Pushing the last line
push (@$table, {row => $row});
}
## ## $table
$template->param( table => $table );

View File

@ -69,15 +69,22 @@
<th scope="row" style="background-color:#FFCB2F;font-weight:normal" title="Module upgrade needed">
[% END %]
[% ELSE %]
[% IF ( ro.require ) %]
[% IF ( ro.name == '' ) %]
<th>
[% ELSIF ( ro.require ) %]
<th scope="row" style="background-color:#FF8A8A;font-weight:bold;" title="Required module missing">
[% ELSE %]
<th scope="row" style="background-color:#FF8A8A;font-weight:normal" title="Optional module missing">
[% END %]
[% END %]
[% ro.name %]
[% ro.name %]
</th>
[% IF ( ro.version ) %]<td>[% ro.version %][% ELSE %]<td style="font-weight:bold">Not Installed[% END %]</td>
[% IF ( ro.name == '' ) %]
<td>
[% ELSIF ( ro.version ) %]
<td>[% ro.version %]
[% ELSE %]
<td style="font-weight:bold">Not Installed [% END %]</td>
[% END %]
</tr>
[% END %]