[Bps-public-commit] r10978 - RT-Extension-Reports/html/Reports/Types

sunnavy at bestpractical.com sunnavy at bestpractical.com
Mon Mar 3 04:33:36 EST 2008


Author: sunnavy
Date: Mon Mar  3 04:33:36 2008
New Revision: 10978

Modified:
   RT-Extension-Reports/html/Reports/Types/Created

Log:
let the axis be date:queue, though not good still. need more work

Modified: RT-Extension-Reports/html/Reports/Types/Created
==============================================================================
--- RT-Extension-Reports/html/Reports/Types/Created	(original)
+++ RT-Extension-Reports/html/Reports/Types/Created	Mon Mar  3 04:33:36 2008
@@ -154,9 +154,18 @@
         }
     }
 
-    if ( $ARGS{csv} || $ARGS{chart} ) {
+    if ( $ARGS{csv} ) {
         $m->comp( '/Reports/Elements/ShowResults', Headers => \@headers,
-Results => \@results, Type => $ARGS{csv} ? 'csv' : 'chart' );
+Results => \@results, Type => 'csv' );
+    }
+    elsif ( $ARGS{chart} ) {
+        for ( @results ) {
+            splice @$_, 0, 2, $_->[1] ? ( join ':', @$_[0 .. 1] ) : $_->[0];
+        }
+        splice @headers, 0, 2, $headers[0 .. 1 ];
+
+        $m->comp( '/Reports/Elements/ShowResults', Headers => \@headers,
+Results => \@results, Type => 'chart' );
     }
 }
 else {



More information about the Bps-public-commit mailing list