Checkpoint: Audit de robustesse et maintenabilité : calcul dynamique des tendances OPEX par véritable année N-1, filtrage/validation centralisés des codes établissement, transactions d'import et d'écriture, contraintes uniques CAPEX/OPEX avec déduplication, suppression effective de postes OPEX, nettoyage des gabarits et scripts morts, chargement différé XLSX, documentation métier et 22 tests passants.
This commit is contained in:
@@ -20,7 +20,7 @@ function SortIcon({ field, sortField, sortOrder }: { field: SortField; sortField
|
||||
: <ArrowDown className="w-3.5 h-3.5 text-primary" />;
|
||||
}
|
||||
|
||||
function VetusteBar({ value, total, color }: { value: number; total: number; color: string }) {
|
||||
function VetusteBar({ value, total }: { value: number; total: number }) {
|
||||
const pct = total > 0 ? Math.round((value / total) * 100) : 0;
|
||||
const barColor =
|
||||
pct >= 80 ? 'bg-red-500' :
|
||||
@@ -133,12 +133,12 @@ export function EtablissementListView({ etablissements, onSelect, sortField, sor
|
||||
|
||||
{/* PC Fixes */}
|
||||
<td className="px-3 py-3">
|
||||
<VetusteBar value={nbFixesR} total={nbFixesTotal} color="blue" />
|
||||
<VetusteBar value={nbFixesR} total={nbFixesTotal} />
|
||||
</td>
|
||||
|
||||
{/* PC Portables */}
|
||||
<td className="px-3 py-3">
|
||||
<VetusteBar value={nbPortablesR} total={nbPortablesTotal} color="orange" />
|
||||
<VetusteBar value={nbPortablesR} total={nbPortablesTotal} />
|
||||
</td>
|
||||
|
||||
{/* Total à renouveler */}
|
||||
|
||||
Reference in New Issue
Block a user