]> git.ipfire.org Git - thirdparty/bugzilla.git/commitdiff
Bug 624414: BUGZILLA.value_descs was always empty in the JS, and display_value
authorMax Kanat-Alexander <mkanat@bugzilla.org>
Wed, 2 Mar 2011 08:41:16 +0000 (00:41 -0800)
committerMax Kanat-Alexander <mkanat@bugzilla.org>
Wed, 2 Mar 2011 08:41:16 +0000 (00:41 -0800)
wasn't translating values.
r=glob, a=mkanat

template/en/default/global/field-descs.none.tmpl
template/en/default/global/header.html.tmpl
template/en/default/global/value-descs.js.tmpl
template/en/default/global/value-descs.none.tmpl [new file with mode: 0644]

index e85ebbee1f6ddc8666527af2e9ce323dab7431d7..479944ff9df73f5aaa8cc88f5e01c4e6390bdfaf 100644 (file)
                 } %]
 
 [% IF in_template_var %]
-
-  [%# You can use this hash to localize (translate) the values displayed
-    # for drop-down and multiple-select fields. Lines starting with "#"
-    # are comments.
-    #%]
-  [% value_descs = {
-    "bug_status" => {
-      # "UNCONFIRMED" => "UNCO",
-      # "CONFIRMED"   => "ITSABUG",
-    },
-
-    "resolution" => {
-      ""        => "---",
-      # "FIXED"      => "NO LONGER AN ISSUE",
-      # "WORKSFORME" => "NOTMYPROBLEM!",
-    },
-  } %]
-
-  [% vars.terms = terms %]
+  [% PROCESS "global/value-descs.none.tmpl" %]
+  [% SET vars.value_descs = value_descs %]
+  [% SET vars.terms = terms %]
 
   [%# field_descs is loaded as a global template variable and cached
     # across all templates--see VARIABLES in Bugzilla/Template.pm.
index df5786abfab8bda841fa0fc35f8a1208226c1f47..2da2d642d37077c29241f5b7a97d4661becbc36d 100644 (file)
 
         [% FOREACH yui_name = yui %]
           [% FOREACH yui_template = yui_templates.$yui_name %]
-            [% PROCESS $yui_template %]
+            [% INCLUDE $yui_template %]
           [% END %]
         [% END %]
         [% IF javascript %]
index d432cf13544d77b69c1ac6c206b28190b0a3d1d2..20d023b42d3e5eef5a568d062f5feab54c91ccca 100644 (file)
@@ -18,7 +18,7 @@
   #   Max Kanat-Alexander <mkanat@bugzilla.org>
   #%]
 
-[% PROCESS "global/field-descs.none.tmpl" %]
+[% PROCESS "global/value-descs.none.tmpl" %]
 
 BUGZILLA.value_descs = {
   [% FOREACH vd_field = value_descs.keys %]
diff --git a/template/en/default/global/value-descs.none.tmpl b/template/en/default/global/value-descs.none.tmpl
new file mode 100644 (file)
index 0000000..56c90ac
--- /dev/null
@@ -0,0 +1,36 @@
+[%# The contents of this file are subject to the Mozilla Public
+  # License Version 1.1 (the "License"); you may not use this file
+  # except in compliance with the License. You may obtain a copy of
+  # the License at http://www.mozilla.org/MPL/
+  #
+  # Software distributed under the License is distributed on an "AS
+  # IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
+  # implied. See the License for the specific language governing
+  # rights and limitations under the License.
+  #
+  # The Original Code is the Bugzilla Bug Tracking System.
+  #
+  # The Initial Developer of the Original Code is BugzillaSource, Inc.
+  # Portions created by the Initial Developer are Copyright (C) 2011 
+  # the Initial Developer. All Rights Reserved.
+  #
+  # Contributor(s):
+  #   Max Kanat-Alexander <mkanat@bugzilla.org>
+  #%]
+
+[%# You can use this hash to localize (translate) the values displayed
+  # for drop-down and multiple-select fields. Lines starting with "#"
+  # are comments.
+  #%]
+[% value_descs = {
+  "bug_status" => {
+    # "UNCONFIRMED" => "UNCO",
+    # "CONFIRMED"   => "ITSABUG",
+  },
+
+  "resolution" => {
+    ""        => "---",
+    # "FIXED"      => "NO LONGER AN ISSUE",
+    # "WORKSFORME" => "NOTMYPROBLEM!",
+  },
+} %]