Remove Cobrar button from Notas de Remision list
Some checks failed
CI / lint-and-test (3.11) (push) Has been cancelled
CI / lint-and-test (3.13) (push) Has been cancelled

This commit is contained in:
2026-07-18 17:25:24 +00:00
parent 667cd3b1eb
commit a4f90cd4a3
2 changed files with 3 additions and 9 deletions

View File

@@ -315,9 +315,7 @@
return;
}
tbody.innerHTML = rows.map(r => {
const canPay = r.status === 'pending_payment';
return `
tbody.innerHTML = rows.map(r => `
<tr>
<td class="td--mono">NR-${r.id}</td>
<td>${new Date(r.created_at).toLocaleString('es-MX')}</td>
@@ -331,14 +329,10 @@
<button class="action-btn action-btn--ghost" onclick="viewTicket(${r.id})" title="Imprimir">
<svg viewBox="0 0 24 24"><polyline points="6 9 6 2 18 2 18 9"/><path d="M6 18H4a2 2 0 0 1-2-2v-5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2v5a2 2 0 0 1-2 2h-2"/><rect x="6" y="14" width="12" height="8"/></svg>
</button>
${canPay ? `<button class="action-btn action-btn--primary" onclick="payNote(${r.id}, ${r.total})" title="Cobrar">
<svg viewBox="0 0 24 24"><rect x="2" y="6" width="20" height="12" rx="2"/><path d="M6 10h.01M6 14h.01"/></svg>
</button>` : ''}
</div>
</td>
</tr>
`;
}).join('');
`).join('');
if (pagination.total_pages > 1) {
pag.innerHTML = `