Use regular match data

This commit is contained in:
AMay 2026-10-24 02:41:31 -05:00
parent 85f65ae32d
commit f5de5fb23e

View File

@ -35,7 +35,7 @@ export function Pool({userRole,name,matches,players,footer,cab}){
}} onBlur={(ev)=>{
fetch("api/updateScore",{
method:"POST",
body:{match_id:`${match[0]}_${match[1]}`,ex1:ev.currentTarget.value,ex2:prevMatchData[ind][1]}
body:{match_id:`${match[0]}_${match[1]}`,ex1:ev.currentTarget.value,ex2:matchData[ind][1]}
})
}} defaultValue={matchData[ind][0]} className="border border-black" type="number" min={0} max={9999}/>:<>{matchData[ind][0]==0?"-":matchData[ind][0]}</>}</td>
<td className="border border-gray-300 p-3">vs</td>
@ -46,7 +46,7 @@ export function Pool({userRole,name,matches,players,footer,cab}){
}} onBlur={(ev)=>{
fetch("api/updateScore",{
method:"POST",
body:{match_id:`${match[0]}_${match[1]}`,ex1:prevMatchData[ind][0],ex2:ev.currentTarget.value}
body:{match_id:`${match[0]}_${match[1]}`,ex1:matchData[ind][0],ex2:ev.currentTarget.value}
})
}} defaultValue={matchData[ind][1]} className="border border-black" type="number" min={0} max={9999}/>:<>{matchData[ind][1]==0?"-":matchData[ind][1]}</>}</td>
<td className={(GetPlayer(match[1]).length>12?"text-xs ":GetPlayer(match[1]).length>8&&"text-sm ")+"border border-gray-300 p-1"}>{GetPlayer(match[1])} {Number.isInteger(match[1])&&<sub className="text-[8px] md:text-sm">({match[1]})</sub>}</td>