[Rt-commit] r18047 - in rt/3.999/branches/merge_to_3.8.2: share/html/Elements/CollectionAsTable

sunnavy at bestpractical.com sunnavy at bestpractical.com
Thu Jan 29 09:43:00 EST 2009


Author: sunnavy
Date: Thu Jan 29 09:43:00 2009
New Revision: 18047

Modified:
   rt/3.999/branches/merge_to_3.8.2/   (props changed)
   rt/3.999/branches/merge_to_3.8.2/share/html/Elements/CollectionAsTable/Header

Log:
 r19273 at sunnavys-mb:  sunnavy | 2009-01-29 22:25:32 +0800
 merged share/html/Elements/CollectionAsTable/Header


Modified: rt/3.999/branches/merge_to_3.8.2/share/html/Elements/CollectionAsTable/Header
==============================================================================
--- rt/3.999/branches/merge_to_3.8.2/share/html/Elements/CollectionAsTable/Header	(original)
+++ rt/3.999/branches/merge_to_3.8.2/share/html/Elements/CollectionAsTable/Header	Thu Jan 29 09:43:00 2009
@@ -86,9 +86,13 @@
         next;
     }
 
-    $item++;
+    my $span = $col->{'span'};
+    $item += ($span || 1);
 
-    $m->out('<th class="collection-as-table">');
+    $m->out('<th class="collection-as-table"');
+    $m->out('colspan="' . $m->interp->apply_escapes($span  => 'h') . '"')
+        if $span;
+    $m->out('>');
 
     $title =~ s/^__(.*)__$/$1/o;
     my $tmp = $m->comp( '/Elements/ColumnMap',
@@ -98,7 +102,7 @@
     );
 
     unless( $tmp ) {
-        $title = $m->interp->apply_escapes( _($title), 'h' );
+        $title = $m->comp('/Elements/ScrubHTML', content => $title);
     } else {
         if ( UNIVERSAL::isa( $tmp, 'CODE' ) ) {
             my @tmp = $tmp->( $title );
@@ -134,11 +138,11 @@
                 %$generic_query_args,
                 order_by => $attr, order => $new_order
             )
-            . '">'. $title .'</a>'
+            . '">'. _($title) .'</a>'
         );
     }
     else {
-        $m->out( $title );
+        $m->out( _($title) );
     }
     $m->out('</th>');
 }


More information about the Rt-commit mailing list