JSFiddle - React, Tailwind, and code Playground
HTML
<table id="tableReport" class="tablePanier">
<tbody>
<tr>
<th class="titles">GenCod</th>
<th class="titles">Auteur</th>
<th class="titles">Titre</th>
<th class="titles">Quantite</th>
<th class="titles">PrixTTC</th>
<th class="titles">TotalPrixTTC</th>
<th class="titles">Delete</th>
</tr>
<tr class="line_hover">
<td>9782871421801</td>
<td>CHAPMAN , JANE</td>
<td>OEUFS DE PAULETTE (LES)</td>
<td>
<input
id="Quantity9782871421801"
onClick="ReCalculateTotal(9782871421801);"
value="1"
min="1"
type="number"
name="fname"
style=" width: 100px; text-align: center; "
/>
</td>
<td id="Prix_TTC">
<input
id="Prix_TTC9782871421801"
type="text"
value="5.2"
name="Prix_TTC"
style=" width: 100px; text-align: center; "
disabled=""
/>
</td>
<td>
<input
id="Total9782871421801"
type="text"
name="fname"
value="5.2"
style=" width: 100px; text-align: center; "
disabled=""
/>
</td>
<td>
<a href="#">
<input
type="button"
value="Retirer"
name="fname"
style=" width: 100px; text-align: center; "
/></a>
</td>
</tr>
</tbody>
</table>
JavaScript
function ReCalculateTotal(id) {
var prix_unitaire = document.getElementById('Prix_TTC'+ id).value;
var quantite = document.getElementById('Quantity'+ id).value;
document.getElementById('Total'+ id).value = Math.round((prix_unitaire * quantite) * 1000) / 1000;
}