Author: spadkins
Date: Thu Sep 10 13:26:36 2009
New Revision: 13300

Modified:
   p5ee/trunk/App-Widget/lib/App/Widget/Graph.pm

Log:
rate.analysis.price GRAPHS now working in dashboards, price GRAPHS now working 
in dashboards

Modified: p5ee/trunk/App-Widget/lib/App/Widget/Graph.pm
==============================================================================
--- p5ee/trunk/App-Widget/lib/App/Widget/Graph.pm       (original)
+++ p5ee/trunk/App-Widget/lib/App/Widget/Graph.pm       Thu Sep 10 13:26:36 2009
@@ -362,6 +362,8 @@
         foreach my $object (@$objects) {
             $x_value = $object->{$x_column};
             $y_value = $object->{$y_column};
+#print STDERR "x_column=[$x_column] [$column_defs->{$x_column}{domain}] 
x_value=[$x_value]\n";
+#print STDERR "y_column=[$y_column] [$column_defs->{$y_column}{domain}] 
y_value=[$y_value]\n";
             if (! defined $x_idx{$x_value}) {
                 my $val_domain = $column_defs->{$x_column}{domain};
                 if (defined $val_domain) {
@@ -374,7 +376,15 @@
                 $x_idx{$x_value} = $#x;
             }
             if (! defined $y_idx{$y_value}) {
-                push(@y, $y_value);
+                my $val_domain = $column_defs->{$y_column}{domain};
+                if (defined $val_domain) {
+#print STDERR "y_column=[$y_column] [$column_defs->{$y_column}{domain}] 
y_value=[$y_value]\n";
+                    my $new_y_val = App::Widget->format($y_value, { domain => 
$val_domain});
+                    push(@y, $new_y_val);
+                }
+                else {
+                    push(@y, $y_value);
+                }
                 $y_idx{$y_value} = $#y;
             }
             $yn_val = $object->{$column};

Reply via email to