mirror of
https://gitlab.com/animath/si/plateforme.git
synced 2025-06-24 09:08:50 +02:00
@ -144,10 +144,10 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||
let poolListId = `recap-${tournament.id}-round-${round}-pool-list`
|
||||
let poolList = document.getElementById(poolListId)
|
||||
if (poolList === null) {
|
||||
let li = document.createElement('li')
|
||||
li.id = `recap-${tournament.id}-round-${round}`
|
||||
li.classList.add('list-group-item')
|
||||
li.setAttribute('data-tournament', tournament.id)
|
||||
let div = document.createElement('div')
|
||||
div.id = `recap-${tournament.id}-round-${round}`
|
||||
div.classList.add('col-md-6', 'px-3', 'py-3')
|
||||
div.setAttribute('data-tournament', tournament.id)
|
||||
|
||||
let title = document.createElement('strong')
|
||||
title.textContent = 'Tour ' + round
|
||||
@ -156,8 +156,8 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||
poolList.id = poolListId
|
||||
poolList.classList.add('list-group', 'list-group-flush')
|
||||
|
||||
li.append(title, poolList)
|
||||
roundList.append(li)
|
||||
div.append(title, poolList)
|
||||
roundList.append(div)
|
||||
}
|
||||
|
||||
let c = 1
|
||||
@ -168,7 +168,7 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||
if (teamList === null) {
|
||||
let li = document.createElement('li')
|
||||
li.id = `recap-${tournament.id}-round-${round}-pool-${poule.letter}`
|
||||
li.classList.add('list-group-item')
|
||||
li.classList.add('list-group-item', 'px-3', 'py-3')
|
||||
li.setAttribute('data-tournament', tournament.id)
|
||||
|
||||
let title = document.createElement('strong')
|
||||
@ -250,7 +250,7 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||
if (pouleTable === null) {
|
||||
// Create table
|
||||
let card = document.createElement('div')
|
||||
card.classList.add('card')
|
||||
card.classList.add('card', 'my-3')
|
||||
tablesRoundDiv.append(card)
|
||||
|
||||
let cardHeader = document.createElement('div')
|
||||
@ -395,16 +395,16 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||
}
|
||||
|
||||
function updateActiveRecap(round, pool, team) {
|
||||
document.querySelectorAll(`li.list-group-item-primary[data-tournament="${tournament.id}"]`)
|
||||
.forEach(elem => elem.classList.remove('list-group-item-primary'))
|
||||
document.querySelectorAll(`div.text-bg-secondary[data-tournament="${tournament.id}"]`)
|
||||
.forEach(elem => elem.classList.remove('text-bg-secondary'))
|
||||
document.querySelectorAll(`li.list-group-item-success[data-tournament="${tournament.id}"]`)
|
||||
.forEach(elem => elem.classList.remove('list-group-item-success'))
|
||||
document.querySelectorAll(`li.list-group-item-info[data-tournament="${tournament.id}"]`)
|
||||
.forEach(elem => elem.classList.remove('list-group-item-info'))
|
||||
|
||||
let roundLi = document.getElementById(`recap-${tournament.id}-round-${round}`)
|
||||
if (roundLi !== null)
|
||||
roundLi.classList.add('list-group-item-primary')
|
||||
let roundDiv = document.getElementById(`recap-${tournament.id}-round-${round}`)
|
||||
if (roundDiv !== null)
|
||||
roundDiv.classList.add('text-bg-secondary')
|
||||
|
||||
let poolLi = document.getElementById(`recap-${tournament.id}-round-${round}-pool-${pool}`)
|
||||
if (poolLi !== null)
|
||||
|
Reference in New Issue
Block a user