+% if ( %pmt_type_subtotal ) {
+ <table class="gridreport" style="margin-left: 2em;">
+ <tr>
+ <th class="gridreport" colspan="2">
+ Summary
+ </th>
+ </tr>
+% for my $pmt_type ( sort keys %pmt_type_subtotal ) {
+ <tr class="gridreport">
+ <td class="gridreport" style="text-align: right; margin-right: 1em;">
+ <% sprintf '$%.2f', $pmt_type_subtotal{ $pmt_type } %>
+ </td>
+ <td class="gridreport">
+ <% $pmt_type |h %>
+ </td>
+ </tr>
+% }
+% if ( keys %pmt_type_subtotal > 1 ) {
+% $pmt_type_subtotal{Total} += $_ for values %pmt_type_subtotal;
+ <tr class="gridreport" style="border-top: solid 1px #999;">
+ <td class="gridreport" style="text-align: right; margin-right: 1em; border-top: solid 1px #666;">
+ <% sprintf( '$%.2f', $pmt_type_subtotal{Total} ) %>
+ </td>
+ <td class="gridreport" style="border-top: solid 1px #666;">
+ Total
+ </td>
+ </tr>
+ </table>
+% }
+% }