summaryrefslogtreecommitdiffstats
path: root/template/en/default/reports/series-common.html.tmpl
diff options
context:
space:
mode:
Diffstat (limited to 'template/en/default/reports/series-common.html.tmpl')
-rw-r--r--template/en/default/reports/series-common.html.tmpl30
1 files changed, 15 insertions, 15 deletions
diff --git a/template/en/default/reports/series-common.html.tmpl b/template/en/default/reports/series-common.html.tmpl
index b8032255d..7bf387bd2 100644
--- a/template/en/default/reports/series-common.html.tmpl
+++ b/template/en/default/reports/series-common.html.tmpl
@@ -20,7 +20,7 @@
[%# INTERFACE:
# donames: boolean. True if we have a multi-select for names as well as
- # categories and subcategories.
+ # categories and subcategories.
# category: hash (keyed by category) of hashes (keyed by subcategory) of
# hashes (keyed by name), with value being the series_id of the
# series. Contains details of all series the user can see.
@@ -38,55 +38,55 @@ var series = {
"[%+ s FILTER js %]" : {
[% IF donames %]
[% FOREACH n = category.$c.$s.keys.sort %]
- "[% n FILTER js %]":
+ "[% n FILTER js %]":
[% category.$c.$s.$n FILTER js %][% ", " UNLESS loop.last %]
[% END %]
[% END %]
}[% ", " UNLESS loop.last %]
[% END %]
}[% ", " UNLESS loop.last %]
-[% END %]
+[% END %]
};
[%# This function takes necessary action on selection of a category %]
function catSelected() {
var cat = document.chartform.category.value;
var subcats = series[cat];
-
+
var subcatwidget = document.chartform.subcategory;
-
+
subcatwidget.options.length = 0;
var i = 0;
-
+
for (x in subcats) {
subcatwidget.options[i] = new Option(x, x);
i++;
}
-
+
[% IF newtext %]
subcatwidget.options[i] = new Option("[% newtext FILTER js %]", "");
- [% END %]
+ [% END %]
subcatwidget.disabled = false;
subcatwidget.options[0].selected = true;
-
+
if (document.chartform.action[1]) {
[%# On the query form, select the right radio button. %]
document.chartform.action[1].checked = true;
}
-
- checkNewState();
+
+ checkNewState();
}
[%# This function updates the disabled state of the two "new" textboxes %]
function checkNewState() {
var fm = document.chartform;
if (fm.newcategory) {
- fm.newcategory.disabled =
- (fm.category.value != "" ||
+ fm.newcategory.disabled =
+ (fm.category.value != "" ||
fm.action[1] && fm.action[1].checked == false);
- fm.newsubcategory.disabled =
- (fm.subcategory.value != "" ||
+ fm.newsubcategory.disabled =
+ (fm.subcategory.value != "" ||
fm.action[1] && fm.action[1].checked == false);
}
}