feat(F-083): completed feature
This commit is contained in:
@@ -195,7 +195,26 @@ export default function CustomersPage() {
|
||||
{c.createdAt ? new Date(c.createdAt).toLocaleDateString('es-ES') : '—'}
|
||||
</td>
|
||||
<td className="px-4 py-3.5">
|
||||
<RowActions onEdit={() => router.push(`/customers/${c.id}`)} />
|
||||
<div className="flex items-center gap-1">
|
||||
<button
|
||||
onClick={async () => {
|
||||
setMsg(`Enviando enlace de recuperación a ${c.email}...`);
|
||||
try {
|
||||
await customersApi.sendPasswordResetLink(c.email);
|
||||
setMsg(`✓ Enlace enviado a ${c.email}`);
|
||||
} catch {
|
||||
setMsg(`✗ No se pudo enviar el enlace a ${c.email}`);
|
||||
} finally {
|
||||
setTimeout(() => setMsg(''), 4000);
|
||||
}
|
||||
}}
|
||||
title="Enviar enlace de recuperación de contraseña"
|
||||
className="px-2 py-1 text-xs text-[#2D6A4F] hover:bg-green-50 rounded-lg transition-colors"
|
||||
>
|
||||
🔑
|
||||
</button>
|
||||
<RowActions onEdit={() => router.push(`/customers/${c.id}`)} />
|
||||
</div>
|
||||
</td>
|
||||
</tr>
|
||||
))}
|
||||
|
||||
Reference in New Issue
Block a user