feat: restringe soloAdmin (Bucefalo CRM) a agentes, default WhatsApp+fallbackEmail y archivado reversible

This commit is contained in:
urieljareth
2026-11-25 08:54:28 -06:00
parent 0d4f19f35d
commit 670265a390
31 changed files with 672 additions and 78 deletions
@@ -39,11 +39,11 @@ export function CambiarEstadoButtons({
const [loading, setLoading] = useState(false);
const [showEnviarModal, setShowEnviarModal] = useState(false);
const [canal, setCanal] = useState<"email" | "whatsapp_chatwoot" | "manual">(
clienteEmail ? "email" : clienteTelefono ? "whatsapp_chatwoot" : "manual"
clienteTelefono ? "whatsapp_chatwoot" : clienteEmail ? "email" : "manual"
);
const [destino, setDestino] = useState(clienteEmail || clienteTelefono || "");
const [destino, setDestino] = useState(clienteTelefono || clienteEmail || "");
const [mensaje, setMensaje] = useState("");
const [fallbackEmail, setFallbackEmail] = useState(Boolean(clienteEmail));
const [fallbackEmail, setFallbackEmail] = useState(true);
const handleAprobar = async () => {
const ok = await confirm({