Here is the code snippet:
<script type="text/javascript>
$(window).load(function(){
debugger
$('#comp').ready(function() {
$('#QV101').css("display", "inline");
$('#QV102').css("display", "none");
$('#QV103').css("display", "none");
});
$('#comp').on('click', function(event) {
debugger
$('#QV101').css("display", "inline");
$('#QV102').css("display", "none");
$('#QV103').css("display", "none");
});
$('#mes').on('click', function(event) {
debugger
$('#QV101').css("display", "none");
$('#QV102').css("display", "inline");
$('#QV103').css("display", "none");
});
$('#hora').on('click', function(event) {
debugger
$('#QV102').css("display", "none");
$('#QV101').css("display", "none");
$('#QV103').css("display", "inline");
});
debugger
});
</script>
The issue I am facing is that when I click on other buttons, such as 'mes' or 'hora', the elements do not display despite the CSS changes being reflected in the web console. I prefer to avoid using 'hidden' as it creates an unsightly gap on the screen.
The HTML code contains values like #QV... which are related to Qlik and display a chart.
Comparativa Consumo mes consumo hora Consumo dia
<div id="QV101" class="col-md-12 qvobject">
</div>
<div id="QV102" class="col-md-12 qvobject">
</div>
<div id="QV103" class="col-md-12 qvobject">
</div>
</div>
<div class="row">
<div id="QV114" class="col-md-2 qvplaceholder">
</div>
<div id="QV115" class="col-md-2 qvplaceholder">
</div>
<div id="QV117" class="col-md-2 qvplaceholder">
</div>
</div>
</div>
</div>
Thank you!