]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 780675: Display "The changes to your votes have been saved" in green instead...
authorSunil Joshi <joshi_sunil@in.com>
Fri, 14 Dec 2012 14:55:23 +0000 (15:55 +0100)
committerFrédéric Buclin <LpSolit@gmail.com>
Fri, 14 Dec 2012 14:55:23 +0000 (15:55 +0100)
r/a=LpSolit

extensions/Voting/Extension.pm
extensions/Voting/template/en/default/hook/global/messages-messages.html.tmpl [new file with mode: 0644]
extensions/Voting/template/en/default/pages/voting/user.html.tmpl

index 03397eaf465829b2c41fa09aae46572cacba0f13..981751a3434048cd331cd5398b94041b2a6ba7ca 100644 (file)
@@ -628,7 +628,7 @@ sub _update_votes {
         # Set header_done to 1 only after the first bug.
         $vars->{'header_done'} = 1;
     }
-    $vars->{'votes_recorded'} = 1;
+    $vars->{'message'} = 'votes_recorded';
 }
 
 ######################
diff --git a/extensions/Voting/template/en/default/hook/global/messages-messages.html.tmpl b/extensions/Voting/template/en/default/hook/global/messages-messages.html.tmpl
new file mode 100644 (file)
index 0000000..74a2d93
--- /dev/null
@@ -0,0 +1,16 @@
+[%# This Source Code Form is subject to th  e terms of the Mozilla Public\r
+  # License, v. 2.0. If a copy of the MPL was not distributed with this\r
+  # file, You can obtain one at http://mozilla.org/MPL/2.0/.\r
+  #\r
+  # This Source Code Form is "Incompatible With Secondary Licenses", as\r
+  # defined by the Mozilla Public License, v. 2.0.\r
+  #%]\r
+\r
+[%# This is a list of all the possible messages. Please keep them in\r
+  # alphabetical order by message tag, and leave a blank line between messages.\r
+  #%]\r
+  \r
+[% IF message_tag == "votes_recorded" %]\r
+    The changes to your votes have been saved.\r
+[% END %]\r
+\r
index 6705b9c370e1dcbea138dbfe19cabb1fc2506994..b1cf53a852db0900431acbe2b848691d194cd4c5 100644 (file)
   <hr>
 [% END %]
 
-[% IF votes_recorded %]
-  <p>
-    <font color="red">
-      The changes to your votes have been saved.
-    </font>
-  </p>
-[% ELSE %]
-  <br>
-[% END %]
-
 [% IF products.size %]
   <form name="voting_form" method="post" action="page.cgi?id=voting/user.html">
     <input type="hidden" name="action" value="vote">