From 0cd4b869322d7f338412d604f2756d64057c9db0 Mon Sep 17 00:00:00 2001 From: "lpsolit%gmail.com" <> Date: Wed, 18 Apr 2007 03:08:06 +0000 Subject: Bug 258647: productmenu.js and productform.js should be consolidated - Patch by Teemu Mannermaa r=myk a=LpSolit --- template/en/default/global/js-products.html.tmpl | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'template/en/default/global/js-products.html.tmpl') diff --git a/template/en/default/global/js-products.html.tmpl b/template/en/default/global/js-products.html.tmpl index 57126f004..dbc1c2e1e 100644 --- a/template/en/default/global/js-products.html.tmpl +++ b/template/en/default/global/js-products.html.tmpl @@ -22,12 +22,14 @@ [%# The javascript block gets used in header.html.tmpl. %] [% javascript = BLOCK %] - var usetms = 0; // do we have target milestone? - var first_load = 1; // is this the first time we load the page? - var last_sel = []; // caches last selection + var useclassification = false; // No classification level in use + var first_load = true; // Is this the first time we load the page? + var last_sel = []; // Caches last selection var cpts = new Array(); + [% n = 1 %] [% FOREACH prod = products %] - cpts['[% prod.name FILTER js %]'] = [ + cpts['[% n %]'] = [ [%- FOREACH comp = prod.components %]'[% comp.name FILTER js %]'[% ", " UNLESS loop.last %] [%- END -%] ]; + [% n = n+1 %] [% END %] [% END %] -- cgit v1.2.3-24-g4f1b