Private
Public Access
1
0

added flexall

This commit is contained in:
Sander Roosendaal
2019-04-29 20:34:59 +02:00
parent a670ee0884
commit 256dd25df2
3 changed files with 114 additions and 5 deletions

View File

@@ -72,12 +72,20 @@
var plotfield = $("#id_plotfield").parent().parent();
var x_param = $("#id_xparam").parent().parent();
var y_param = $("#id_yparam").parent().parent();
var groupby = $("#id_groupby").parent().parent();
var binsize = $("#id_binsize").parent().parent();
var errorbars = $("#id_ploterrorbars").parent().parent();
var palette = $("#id_palette").parent().parent();
var spmmin = $("#id_spmmin").parent().parent();
var spmmax = $("#id_spmmax").parent().parent();
var workmin = $("#id_workmin").parent().parent();
var workmax = $("#id_workmax").parent().parent();
var xaxis = $("#id_xaxis").parent().parent();
var yaxis1 = $("#id_yaxis1").parent().parent();
var yaxis2 = $("#id_yaxis2").parent().parent();
// Hide the fields.
// Use JS to do this in case the user doesn't have JS
// enabled.
@@ -88,6 +96,9 @@
errorbars.hide();
palette.hide();
binsize.hide();
xaxis.hide();
yaxis1.hide();
yaxis2.hide();
if (functionfield.val() == 'boxplot') {
plotfield.show();
@@ -95,7 +106,7 @@
if (functionfield.val() == 'histo') {
plotfield.show()
}
};
if (functionfield.val() == 'trendflex') {
x_param.show();
@@ -106,6 +117,12 @@
errorbars.show();
};
if (functionfield.val() == 'flexall') {
xaxis.show();
yaxis1.show();
yaxis2.show();
}
// Setup an event listener for when the state of the
// checkbox changes.
@@ -117,21 +134,36 @@
if (Value=='boxplot') {
// Show the hidden fields.
plotfield.show();
spmmin.show();
spmmax.show();
workmin.show();
workmax.show();
x_param.hide();
y_param.hide();
groupby.hide();
palette.hide();
binsize.hide();
errorbars.hide();
xaxis.hide();
yaxis1.hide();
yaxis2.hide();
}
else if (Value=='histo') {
plotfield.show();
spmmin.show();
spmmax.show();
workmin.show();
workmax.show();
x_param.hide();
y_param.hide();
groupby.hide();
palette.hide();
binsize.hide();
errorbars.hide();
xaxis.hide();
yaxis1.hide();
yaxis2.hide();
}
else if (Value=='trendflex') {
x_param.show();
@@ -140,12 +172,35 @@
palette.show();
binsize.show();
errorbars.show();
spmmin.show();
spmmax.show();
workmin.show();
workmax.show();
plotfield.hide();
xaxis.hide();
yaxis1.hide();
yaxis2.hide();
}
else if (Value=='flexall') {
xaxis.show();
yaxis1.show();
yaxis2.show();
x_param.hide();
y_param.hide();
groupby.hide();
spmmin.hide();
spmmax.hide();
workmin.hide();
workmax.hide();
plotfield.hide();
palette.hide();
binsize.hide();
errorbars.hide();
}
});
});
});
</script>
<div id="id_css_res">