diff --git a/css/style.css b/css/style.css index 0b52d38..37654fe 100644 --- a/css/style.css +++ b/css/style.css @@ -5067,8 +5067,7 @@ button.inscr-gestion-list-remis:hover{ background:#f7faff; } - .inscr-gestion-list-item__who{ grid-area:name; } - .inscr-gestion-list-item__name{ display:flex; } + .inscr-gestion-list-item__name{ grid-area:name; } .inscr-gestion-list-item__race{ grid-area:race; white-space:normal; diff --git a/php/inc_fx_inscriptions_gestion.php b/php/inc_fx_inscriptions_gestion.php index 7c5c28c..8312dd5 100644 --- a/php/inc_fx_inscriptions_gestion.php +++ b/php/inc_fx_inscriptions_gestion.php @@ -989,6 +989,7 @@ function fxInscrGestionFetchRows($intEveId, $arrReq) { $strWhere = fxInscrGestionBuildWhere($intEveId, $arrReq); // MSIN-4459 — 1 ligne = 1 participant (coéquipiers dans les memes colonnes). + // Equipes regroupées (pec / no_equipe, capitaine d'abord) ; solos par nom. // Exclut rol_id 3/4 (benevole / autre) comme le promoteur. $sql = 'SELECT p.no_bib, p.no_bib_remis, p.no_bib_remis_date, p.no_bib_remis_par, p.par_statut_course, p.par_id, p.par_equipe,' . ' p.par_prenom, p.par_nom, e.pec_id_original, e.epr_id, e.eve_id, e.pec_id, e.is_cancelled, e.pec_actif, p.rol_id,' @@ -997,7 +998,13 @@ function fxInscrGestionFetchRows($intEveId, $arrReq) { . ' WHERE ' . $strWhere . ' AND p.pec_id = e.pec_id_original' . ' AND p.rol_id NOT IN (3, 4)' - . ' ORDER BY p.par_nom, p.par_prenom, p.par_id'; + . ' ORDER BY' + . ' CASE WHEN IFNULL(e.pec_equipe, 0) = 1' + . " THEN CONCAT('T', LPAD(CAST(e.pec_id_original AS CHAR), 11, '0'))" + . " ELSE CONCAT('P', p.par_nom, '\t', p.par_prenom)" + . ' END,' + . ' CASE WHEN p.rol_id = 1 THEN 0 ELSE 1 END,' + . ' p.par_nom, p.par_prenom, p.par_id'; return $objDatabase->fxGetResults($sql); } @@ -2224,25 +2231,15 @@ function fxInscrGestionRenderList($intEveId, $strLangue, $strBaseUrl, $arrReq) { $strRemisLabel = fxInscrGestionT('promoteur_bib_enregistre'); $strBibOkLabel = fxInscrGestionT('inscr_gestion_bib_ok'); - $strTeammateLabel = fxInscrGestionT('inscr_gestion_list_teammate'); - $strCaptainLabel = trim(fxInscrGestionT('participant-titre-capitaine')); - if ($strCaptainLabel === '') { - $strCaptainLabel = ($strLangue === 'en') ? 'Captain' : 'Capitaine'; - } for ($j = $intStart; $j <= $intEnd; $j++) { $row = $tabRows[$j]; $blnEquipe = (intval($row['pec_equipe']) === 1); $intPecId = (int)$row['pec_id_original']; $intParId = (int)$row['par_id']; - $strTeamName = $blnEquipe - ? trim(fxUnescape(isset($row['pec_nom_equipe']) ? $row['pec_nom_equipe'] : '')) - : ''; $strTeamNo = $blnEquipe ? trim(fxUnescape(isset($row['no_equipe']) ? $row['no_equipe'] : '')) : ''; - $blnCapitaine = $blnEquipe && ((int)$row['rol_id'] === 1); - $blnCoequipier = $blnEquipe && !$blnCapitaine; // MSIN-4459 — Fiche cible ce participant (capitaine ou coéquipier). $strFicheUrl = fxInscrGestionBuildUrl($strBaseUrl, $intEveId, $arrReq, array( @@ -2267,9 +2264,6 @@ function fxInscrGestionRenderList($intEveId, $strLangue, $strBaseUrl, $arrReq) { isset($row['par_statut_course']) ? $row['par_statut_course'] : '' ); $strCardClass = 'inscr-gestion-list-item'; - if ($blnCoequipier) { - $strCardClass .= ' inscr-gestion-list-item--teammate'; - } $strCancelBadge = ''; if ($row['is_cancelled'] == '1') { // MSIN-4405 — Cause derivee en lecture seule (aucune ecriture en base). @@ -2281,24 +2275,10 @@ function fxInscrGestionRenderList($intEveId, $strLangue, $strBaseUrl, $arrReq) { $blnRemis = (intval($row['no_bib_remis']) === 1); - // MSIN-4448 / MSIN-4459 — 1 participant = 1 ligne, memes colonnes. + // MSIN-4459 — Meme densite que la liste solo : 1 ligne de nom (+ no equipe entre parentheses). echo '