diff --git a/frontend/src/pages/InvestissementDetail.jsx b/frontend/src/pages/InvestissementDetail.jsx index c90f41d..11fb918 100644 --- a/frontend/src/pages/InvestissementDetail.jsx +++ b/frontend/src/pages/InvestissementDetail.jsx @@ -1199,6 +1199,19 @@ export default function InvestissementDetail() { const interets = netMode ? (s.interets_prevus || 0) * (1 - reduction) : (s.interets_prevus || 0); + + // Montants réels pour comparaison + const interetsReels = isPaid + ? (netMode ? (matched.interets_nets || 0) : (matched.interets_bruts || 0)) + : null; + const totalRecu = isPaid + ? (netMode + ? (matched.net_recu || 0) + : (matched.capital || 0) + (matched.cashback || 0) + (matched.interets_bruts || 0)) + : null; + const interetsDiffers = isPaid && Math.abs(interetsReels - interets) > 0.01; + const totalDiffers = isPaid && Math.abs(totalRecu - s.total_prevu) > 0.01; + return (