]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 142950 - query links in footer are broken. Patch by gerv; r=ddk, afranke.
authorgerv%gerv.net <>
Thu, 9 May 2002 00:58:06 +0000 (00:58 +0000)
committergerv%gerv.net <>
Thu, 9 May 2002 00:58:06 +0000 (00:58 +0000)
buglist.cgi
template/en/default/global/useful-links.html.tmpl

index 4c1719d999e11d99f4f7acea218f5da53a38c657..1dfe52e5aa46bd0fed541426c6d2ec4158960ea2 100755 (executable)
@@ -1124,7 +1124,7 @@ CMD: for ($::FORM{'cmdtype'}) {
         
         # Don't add it to the list if they are reusing an existing query name.
         foreach my $query (@{$vars->{'user'}{'queries'}}) {
-            if ($query->{'name'} eq $name) {
+            if ($query->{'name'} eq $name && $query->{'linkinfooter'} == 1) {
                 $new_in_footer = 0;
             }
         }        
@@ -1132,7 +1132,10 @@ CMD: for ($::FORM{'cmdtype'}) {
         print "Content-Type: text/html\n\n";
         # Generate and return the UI (HTML page) from the appropriate template.        
         if ($new_in_footer) {
-            push(@{$vars->{'user'}{'queries'}}, {name => $name});
+            my %query = (name => $name,
+                         query => $::buffer, 
+                         linkinfooter => $tofooter);
+            push(@{$vars->{'user'}{'queries'}}, \%query);
         }
         
         $vars->{'title'} = "OK, query saved.";
index 90704de1cfbecf06b43d5722475943208b34fdfc..5db6333edb6d002b36842955e7bb4d841aa34197 100644 (file)
@@ -97,7 +97,7 @@
       
       <td colspan="3">
         [% IF user.showmybugslink %]
-          <a href="buglist.cgi?bug_status=NEW&bug_status=ASSIGNED&bug_status=REOPENED&email1=[% user.name FILTER url_quote %]&emailtype1=exact&emailassigned_to1=1&emailreporter1=1">My&nbsp;Bugs
+          <a href="buglist.cgi?bug_status=NEW&amp;bug_status=ASSIGNED&amp;bug_status=REOPENED&amp;email1=[% user.login FILTER url_quote %]&amp;emailtype1=exact&amp;emailassigned_to1=1&amp;emailreporter1=1">My&nbsp;Bugs
           </a>
           [% print_pipe = 1 %]
         [% END %]
         [% FOREACH q = user.queries %]
           [% IF q.linkinfooter %]
             [% " | " IF print_pipe %]
-            <a href="buglist.cgi?cmdtype=runnamed&amp;namedcmd=[% q FILTER url_quote %]">[% q.name FILTER no_break FILTER html %]
+            <a href="buglist.cgi?cmdtype=runnamed&amp;namedcmd=[% q.name FILTER url_quote %]">[% q.name FILTER html FILTER no_break %]
             </a>
             [% print_pipe = 1 %]
           [% END %]