diff --git a/attached_assets/image_1757364497925.png b/attached_assets/image_1757364497925.png new file mode 100644 index 0000000..3dde189 Binary files /dev/null and b/attached_assets/image_1757364497925.png differ diff --git a/client/src/pages/Avoirs.tsx b/client/src/pages/Avoirs.tsx index 8871368..6bf4ee4 100644 --- a/client/src/pages/Avoirs.tsx +++ b/client/src/pages/Avoirs.tsx @@ -989,7 +989,9 @@ export default function Avoirs() {
- {searchTerm ? "Aucun avoir ne correspond à votre recherche." : "Commencez par créer votre premier avoir."} -
- {!searchTerm && ( - - )} -| - Fournisseur - | -- Statut - | -- Référence - | -- Magasin - | -- Montant - | -- Créé le - | -- Vérification - | -- Actions - | -
|---|---|---|---|---|---|---|---|
| - {avoir.supplier?.name || 'Fournisseur non défini'} - | -- - | -- #{avoir.invoiceReference || 'Sans référence'} - | -
-
-
- {avoir.group?.name || 'Magasin non défini'}
-
- |
-
-
- {avoir.amount !== null && avoir.amount !== undefined ? `${Number(avoir.amount).toFixed(2)} €` : 'Non spécifié'}
- {avoir.commercialProcessed && (
-
-
-
- )}
- {avoir.webhookSent && (
-
-
- )}
- |
-
-
-
-
- {avoir?.createdAt
- ? format(new Date(avoir.createdAt), "dd/MM/yyyy", { locale: fr })
- : 'Non défini'
- }
-
-
- Par {avoir?.creator?.firstName && avoir?.creator?.lastName
- ? `${avoir.creator.firstName} ${avoir.creator.lastName}`
- : avoir?.creator?.username || 'Utilisateur inconnu'
- }
-
- |
-
- {avoir.invoiceReference?.trim() ? (
-
- {verifyingAvoirs.has(avoir.id) ? (
-
- ) : (
- Sans réf.
- )}
-
-
- ) : avoirVerificationResults[avoir.id]?.exists === false ? (
- |
-
-
- {/* 📋 Icône Upload pour avoirs "Reçu" */}
- {avoir?.status === 'Reçu' && (
-
- )}
-
- {/* Bouton Valider - apparaît si vérification réussie et pas encore validé */}
- {avoirVerificationResults[avoir.id]?.exists === true && !avoir.nocodbVerified && (
-
- )}
-
- {/* Bouton Dévalider - pour admins sur avoirs validés */}
- {avoir.nocodbVerified && canEditDelete && (
-
- )}
-
- {/* Bouton Commentaire - apparaît seulement s'il y a un commentaire */}
- {avoir.comment && avoir.comment.trim() !== '' && (
-
- )}
-
- {canEditDelete && (
- <>
-
-
- >
- )}
- {!canEditDelete && avoir?.status !== 'Reçu' && (
- Lecture seule
- )}
-
- |
-