La carpeta con .git (C:\Mis Aplicaciones\informe-comercial) quedó desactualizada frente a lo que corre hoy en Coolify (deploy directo por Foundry desde esta carpeta, sin paso por git). Este commit fija esta carpeta como fuente de verdad del repo, con Renovaciones, Actividades, Agenda, Admin/Metas y Nuevas Oportunidades que la copia vieja no tenía. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
49 lines
1.7 KiB
JavaScript
49 lines
1.7 KiB
JavaScript
import { DYN, ACT_COLOR, money2 } from "../../lib/constants";
|
|
import { cierreVencido } from "../../lib/derive";
|
|
|
|
// Tabla del informe individual — puerto de repRow()/repTable() (App Informe/assets/js/modals.js).
|
|
export default function RepTable({ arr }) {
|
|
if (!arr.length) return <p className="hint">Ninguna oportunidad en esta categoría — bien ahí.</p>;
|
|
const sorted = [...arr].sort((a, b) => b.est - a.est);
|
|
return (
|
|
<div className="tw">
|
|
<div className="ts" style={{ maxHeight: "none" }}>
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Cliente</th>
|
|
<th>Oportunidad</th>
|
|
<th>Plan cierre</th>
|
|
<th>Fase actual</th>
|
|
<th>Actividad</th>
|
|
<th className="num">MRR est.</th>
|
|
<th>Cierre est.</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{sorted.map((o) => (
|
|
<tr key={o.id}>
|
|
<td>{o.cliente || "—"}</td>
|
|
<td>
|
|
<a className="opp" href={`${DYN}${o.id}`} target="_blank" rel="noopener">
|
|
{o.name}
|
|
</a>
|
|
</td>
|
|
<td>{(o.plan || "").replace(" - ", " ")}</td>
|
|
<td>{o.faseActual || "—"}</td>
|
|
<td>
|
|
<span style={{ color: ACT_COLOR[o.actividad] || "#9db4c9", fontWeight: 700 }}>● {o.actividad}</span>
|
|
</td>
|
|
<td className="num">{money2(o.est)}</td>
|
|
<td>
|
|
{o.close || "—"}
|
|
{cierreVencido(o) ? " ⚠" : ""}
|
|
</td>
|
|
</tr>
|
|
))}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|