fix: remittances totalAmount+clientId (FIBEROPS-221), create client URL (FIBEROPS-222), tickets /messages (FIBEROPS-224)

This commit is contained in:
root
2026-03-31 04:15:33 +00:00
parent 5843499815
commit a77759cc97
3 changed files with 10 additions and 10 deletions

View File

@@ -114,7 +114,7 @@ export default function RemittancesPage() {
<TableRow key={r.id} data-testid="remittance-row" onClick={() => setSelected(r)} className="cursor-pointer hover:bg-blue-50 transition-colors">
<Td>{formatDate(r.createdAt)}</Td>
<Td className="font-medium">{r.collector ? `${r.collector.firstName} ${r.collector.lastName}` : "—"}</Td>
<Td className="font-semibold text-blue-700">{formatCurrency(Number(r.amount))}</Td>
<Td className="font-semibold text-blue-700">{formatCurrency(Number(r.totalAmount))}</Td>
<Td><Badge variant={statusVariant[r.status] ?? "muted"}>{r.status}</Badge></Td>
<Td className="text-gray-500 text-sm">{r.notes ?? "—"}</Td>
<Td>
@@ -152,7 +152,7 @@ export default function RemittancesPage() {
<div className="space-y-1.5 max-h-48 overflow-y-auto">
{selected.payments.map(p => (
<div key={p.id} className="flex justify-between text-sm bg-white border rounded-lg px-3 py-2">
<span className="text-gray-600">{p.client ? `${p.client.firstName} ${p.client.lastName}` : p.clientId.slice(0, 8)}</span>
<span className="text-gray-600">{p.client ? `${p.client.firstName} ${p.client.lastName}` : p.clientId ? p.clientId.slice(0, 8) : p.id.slice(0, 8)}</span>
<span className="font-medium text-green-700">{formatCurrency(Number(p.amount))}</span>
</div>
))}