[Rt-commit] r11832 - rt/branches/3.8-TESTING/html/Ticket/Graphs

ruz at bestpractical.com ruz at bestpractical.com
Tue Apr 22 20:18:03 EDT 2008


Author: ruz
Date: Tue Apr 22 20:18:01 2008
New Revision: 11832

Modified:
   rt/branches/3.8-TESTING/html/Ticket/Graphs/index.html

Log:
* update saved graphs support

Modified: rt/branches/3.8-TESTING/html/Ticket/Graphs/index.html
==============================================================================
--- rt/branches/3.8-TESTING/html/Ticket/Graphs/index.html	(original)
+++ rt/branches/3.8-TESTING/html/Ticket/Graphs/index.html	Tue Apr 22 20:18:01 2008
@@ -71,7 +71,8 @@
 <& /Search/Elements/EditSearches,
     %$saved_search,
     Title         => loc('Manage saved graphs'),
-    SearchFields   => \@save_arguments,
+    Type          => 'Graph',
+    SearchFields  => \@save_arguments,
     CurrentSearch => { map { $_ => $ARGS{$_} } @save_arguments },
     AllowCopy     => 0,
 &>
@@ -87,7 +88,7 @@
 foreach my $level ( 0 .. 6 ) {
     push @save_arguments, "Level-". $level ."-Properties";
 }
-my $saved_search = { Type => 'Graph' };
+my $saved_search = { };
 push @results, $m->comp( '/Search/Elements/EditSearches:Init',
     %ARGS,
     Query        => \%ARGS,
@@ -103,10 +104,17 @@
 $Type = ucfirst lc $Type;
 unless ( $Type eq 'Links' || $Type eq 'Members' ) {
     $RT::Logger->error("'$Type' is incorrect type of ticket graph");
-    $Type = 'Links';
+    $ARGS{'Type'} = $Type = 'Links';
 }
 $ARGS{'Depth'} = 3 unless defined $ARGS{'Depth'} && length $ARGS{'Depth'};
 
+push @results, $m->comp( '/Search/Elements/EditSearches:Save',
+    %ARGS,
+    Query        => \%ARGS,
+    SavedSearch  => $saved_search,
+    SearchFields => \@save_arguments,
+);
+
 my $title;
 if ( $Type eq 'Links' ) {
     $title = loc( "Ticket #[_1] full relationships graph", $id );


More information about the Rt-commit mailing list