Commit 94460f40 authored by diesys's avatar diesys 🎈

some fix

parent cf53319a
tornelo.code-workspace
data/singolo/
data/doppio/
data/singolo/singolo.json
pomelo.code-workspace
r/
......@@ -67,116 +67,17 @@ window.onload = function () {
});
// select tornei
$('#buttonSingolo').bind('click', function() {
if ($('#singoloRanking').is(':visible') | $('#singoloPartite').is(':visible')) {
$(this).removeClass('active');
$('.buttonSingolo').removeClass('active');
$('.collapse-singolo').fadeOut();
} else {
$(this).addClass('active');
$('.buttonSingolo').addClass('active');
$('.collapse-singolo').fadeIn();
}
});
// select torneo
$('#buttonRankSingolo').bind('click', function() {
bS = $('#buttonSingolo').hasClass('active');
bPS = $('#buttonPartSingolo').hasClass('active');
bRS = $('#buttonRankSingolo').hasClass('active');
if ( bS && bPS && bRS ) {
$('#singoloRanking').fadeOut();
$(this).removeClass('active');
} else if ( bS && bPS ) {
$('#singoloRanking').fadeIn();
$(this).addClass('active');
} else if ( bS ) {
$('#singoloRanking').fadeOut();
$(this).removeClass('active');
$('#buttonSingolo').removeClass('active');
} else {
$('#singoloRanking').fadeIn();
$(this).addClass('active');
$('#buttonSingolo').addClass('active');
}
$('#buttonRanking').bind('click', function() {
$(this).toggleClass('active');
$('#ranking').fadeToggle();
console.log('Toggle ranking table...');
});
$('#buttonPartSingolo').bind('click', function() {
bS = $('#buttonSingolo').hasClass('active');
bPS = $('#buttonPartSingolo').hasClass('active');
bRS = $('#buttonRankSingolo').hasClass('active');
if (bS && bPS && bRS) {
$('#singoloPartite').fadeOut();
$(this).removeClass('active');
} else if (bS && bRS) {
$('#singoloPartite').fadeIn();
$(this).addClass('active');
} else if (bS) {
$('#singoloPartite').fadeOut();
$(this).removeClass('active');
$('#buttonSingolo').removeClass('active');
} else {
$('#singoloPartite').fadeIn();
$(this).addClass('active');
$('#buttonSingolo').addClass('active');
}
});
$('#buttonDoppio').bind('click', function() {
if ($('#doppioRanking').is(':visible') | $('#doppioPartite').is(':visible')) {
$(this).removeClass('active');
$('.buttonDoppio').removeClass('active');
$('.collapse-doppio').fadeOut();
} else {
$(this).addClass('active');
$('.buttonDoppio').addClass('active');
$('.collapse-doppio').fadeIn();
}
});
$('#buttonRankDoppio').bind('click', function () {
bS = $('#buttonDoppio').hasClass('active');
bPS = $('#buttonPartDoppio').hasClass('active');
bRS = $('#buttonRankDoppio').hasClass('active');
if (bS && bPS && bRS) {
$('#doppioRanking').fadeOut();
$(this).removeClass('active');
} else if (bS && bPS) {
$('#doppioRanking').fadeIn();
$(this).addClass('active');
} else if (bS) {
$('#doppioRanking').fadeOut();
$(this).removeClass('active');
$('#buttonDoppio').removeClass('active');
} else {
$('#doppioRanking').fadeIn();
$(this).addClass('active');
$('#buttonDoppio').addClass('active');
}
});
$('#buttonPartDoppio').bind('click', function () {
bS = $('#buttonDoppio').hasClass('active');
bPS = $('#buttonPartDoppio').hasClass('active');
bRS = $('#buttonRankDoppio').hasClass('active');
if (bS && bPS && bRS) {
$('#doppioPartite').fadeOut();
$(this).removeClass('active');
} else if (bS && bRS) {
$('#doppioPartite').fadeIn();
$(this).addClass('active');
} else if (bS) {
$('#doppioPartite').fadeOut();
$(this).removeClass('active');
$('#buttonDoppio').removeClass('active');
} else {
$('#doppioPartite').fadeIn();
$(this).addClass('active');
$('#buttonDoppio').addClass('active');
}
$('#buttonMatches').bind('click', function() {
$(this).toggleClass('active');
$('#partite').fadeToggle();
console.log('Toggle matches table...');
});
}
\ No newline at end of file
......@@ -390,7 +390,7 @@ if(len(sys.argv) > 1): # getting parameters if exist
print("Torneo creato, segui l'help per popolarlo")
elif(options[1] == '--gen-index'):
torneo = options[2]
torneo = importaTorneo(options[2])
costruisciIndexHtml(torneo)
elif(options[1] == '-i' or options[1] == '--import'):
......
......@@ -292,27 +292,20 @@
<br>
<div class='mr-2' role='group' aria-label='1g'>
<div class="btn-group-vertical">
<button id="buttonSingolo" class='btn btn-outline-primary'>
<ion-icon name='ios-contact' size='large'></ion-icon>
<ion-icon name='md-swap'></ion-icon>
<ion-icon name='ios-contact' size='large'></ion-icon>
<div class='btn-group mr-2' role='group' aria-label='2g'>
<button id="buttonRanking" class='btn btn-outline-primary active'>
<ion-icon name='ios-trending-up' size='large'></ion-icon>
</button>
<button id="buttonMatches" class='btn btn-outline-danger active'>
<ion-icon name='ios-list' size='large'></ion-icon>
</button>
<div class='btn-group mr-2' role='group' aria-label='2g'>
<button id="buttonRankSingolo" class='buttonSingolo btn btn-outline-primary'>
<ion-icon name='ios-trending-up' size='large'></ion-icon>
</button>
<button id="buttonPartSingolo" class='buttonSingolo btn btn-outline-primary'>
<ion-icon name='ios-list' size='large'></ion-icon>
</button>
</div>
</div>
</div>
</center>
<div class='row'>
<div class='col fade-table hidden collapse-ranking collapse-singolo' id='singoloRanking'>
<h4 class='titleSection'>Ranking (singolo)</h4>
<div class='col fade-table collapse-ranking' id='ranking'>
<h4 class='titleSection'>Ranking</h4>
<p class='centered'>
<!-- #### RANKING #### -->
......@@ -559,8 +552,8 @@
</p>
</div>
<div class='col fade-table hidden collapse-partite collapse-singolo' id='singoloPartite'>
<h4 class='titleSection''>Partite (singolo)</h4>
<div class='col fade-table collapse-partite' id='partite'>
<h4 class='titleSection''>Partite</h4>
<p class='centered'>
<!-- #### MATCH #### -->
......
......@@ -151,27 +151,20 @@
<br>
<div class='mr-2' role='group' aria-label='1g'>
<div class="btn-group-vertical">
<button id="buttonSingolo" class='btn btn-outline-primary'>
<ion-icon name='ios-contact' size='large'></ion-icon>
<ion-icon name='md-swap'></ion-icon>
<ion-icon name='ios-contact' size='large'></ion-icon>
<div class='btn-group mr-2' role='group' aria-label='2g'>
<button id="buttonRanking" class='btn btn-outline-primary active'>
<ion-icon name='ios-trending-up' size='large'></ion-icon>
</button>
<button id="buttonMatches" class='btn btn-outline-danger active'>
<ion-icon name='ios-list' size='large'></ion-icon>
</button>
<div class='btn-group mr-2' role='group' aria-label='2g'>
<button id="buttonRankSingolo" class='buttonSingolo btn btn-outline-primary'>
<ion-icon name='ios-trending-up' size='large'></ion-icon>
</button>
<button id="buttonPartSingolo" class='buttonSingolo btn btn-outline-primary'>
<ion-icon name='ios-list' size='large'></ion-icon>
</button>
</div>
</div>
</div>
</center>
<div class='row'>
<div class='col fade-table hidden collapse-ranking collapse-singolo' id='singoloRanking'>
<h4 class='titleSection'>Ranking (singolo)</h4>
<div class='col fade-table collapse-ranking' id='ranking'>
<h4 class='titleSection'>Ranking</h4>
<p class='centered'>
<!-- #### RANKING #### -->
......@@ -180,8 +173,8 @@
</p>
</div>
<div class='col fade-table hidden collapse-partite collapse-singolo' id='singoloPartite'>
<h4 class='titleSection''>Partite (singolo)</h4>
<div class='col fade-table collapse-partite' id='partite'>
<h4 class='titleSection''>Partite</h4>
<p class='centered'>
<!-- #### MATCH #### -->
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment