fix: cClassTrib control page tables scroll inside their own container (no page-level horizontal overflow)
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
@@ -230,3 +230,6 @@ button.caution:hover { filter: brightness(1.08); }
|
||||
.failed-job-side { flex: none; display: grid; gap: 4px; justify-items: end; font-size: 0.8rem; color: var(--cor-texto-secundario); white-space: nowrap; }
|
||||
@media (max-width: 520px) { .failed-job { flex-direction: column; } .failed-job-side { justify-items: start; grid-auto-flow: column; gap: 12px; } }
|
||||
.ops-actions button:disabled, .ops-actions .primary-action:disabled { opacity: .45; cursor: not-allowed; filter: grayscale(.4); }
|
||||
.table-wrap table { min-width: 0; }
|
||||
.panel .table-wrap { overflow-x: auto; max-width: 100%; }
|
||||
@media (max-width: 640px) { .table-wrap table { font-size: 0.82rem; } .table-wrap td, .table-wrap th { padding: 6px 8px; } }
|
||||
|
||||
@@ -25,17 +25,17 @@
|
||||
<section class="panel"><div class="panel-title"><div><h2>Candidatos</h2><p class="muted">{{ total }} produto(s) neste filtro.</p></div></div>
|
||||
<nav class="tabs" aria-label="Filtro de candidatos">{% for st, label in [("PENDING","Pendentes"),("APPROVED","Aprovados"),("REJECTED","Rejeitados"),("APPLIED","Aplicados"),("STALE","Obsoletos")] %}<a class="{% if status==st %}active{% endif %}" href="?status={{ st }}">{{ label }} ({{ counts.get(st, 0) }})</a>{% endfor %}</nav>
|
||||
<form method="post" action="/agents/{{ agent_id }}/rtc-candidates"><input type="hidden" name="csrf_token" value="{{ csrf_token }}">
|
||||
<table><thead><tr><th></th><th>Produto</th><th>Descrição</th><th>NCM</th><th>cClassTrib atual</th><th>cClassTrib proposto</th><th>CST IBS/CBS</th><th>Regra</th><th>Fundamento</th><th>Catálogo</th><th>Situação</th></tr></thead><tbody>
|
||||
<div class="table-wrap"><table class="compact-table"><thead><tr><th></th><th>Produto</th><th>Descrição</th><th>NCM</th><th>cClassTrib atual</th><th>cClassTrib proposto</th><th>CST IBS/CBS</th><th>Regra</th><th>Fundamento</th><th>Catálogo</th><th>Situação</th></tr></thead><tbody>
|
||||
{% for c in rows %}<tr><td><input type="checkbox" name="ids" value="{{ c.id }}" aria-label="Selecionar {{ c.product_code }}"></td><td>{{ c.product_code }}</td><td>{{ c.description or "" }}</td><td>{{ c.ncm }}</td><td>{{ c.current_value or "vazio" }}</td><td>{{ c.proposed }}</td><td>{{ c.cst_ibscbs }}</td><td>{{ L.rule(c.rule_id) }}</td><td>{{ c.basis }}</td><td>{{ L.catalog("MATCH_SAFE") }}</td><td>{{ L.status(c.status) }}</td></tr>
|
||||
{% else %}<tr><td colspan="10" class="muted">Nenhum candidato neste filtro.</td></tr>{% endfor %}</tbody></table>
|
||||
{% else %}<tr><td colspan="10" class="muted">Nenhum candidato neste filtro.</td></tr>{% endfor %}</tbody></table></div>
|
||||
<p>Página {{ page }} de {{ pages }}{% if page > 1 %} · <a href="?status={{ status }}&page={{ page - 1 }}">anterior</a>{% endif %}{% if page < pages %} · <a href="?status={{ status }}&page={{ page + 1 }}">próxima</a>{% endif %}</p>
|
||||
<p><button type="submit" name="action" value="approve" class="secondary" {% if not privileged %}disabled{% endif %}>Aprovar selecionados</button> <button type="submit" name="action" value="reject" class="caution">Rejeitar selecionados</button>
|
||||
<button type="submit" name="action" value="approve" class="secondary" formaction="/agents/{{ agent_id }}/rtc-candidates?all=1">Aprovar todos os pendentes</button>
|
||||
{% if mode == "APPROVAL_REQUIRED" %}<button type="submit" name="action" value="apply_approved" class="primary-action">Aplicar aprovados agora</button>{% endif %}</p></form></section>
|
||||
|
||||
<section class="panel"><div class="panel-title"><div><h2>Auditoria e reversão</h2><p class="muted">Cada preenchimento pode ser revertido individualmente, desde que o valor no ERP ainda seja o gravado.</p></div></div>
|
||||
<table><thead><tr><th>#</th><th>Produto</th><th>Ação</th><th>Resultado</th><th>Antes → Depois</th><th>Regra</th><th>Origem</th><th>Reversão</th></tr></thead><tbody>
|
||||
<div class="table-wrap"><table class="compact-table"><thead><tr><th>#</th><th>Produto</th><th>Ação</th><th>Resultado</th><th>Antes → Depois</th><th>Regra</th><th>Origem</th><th>Reversão</th></tr></thead><tbody>
|
||||
{% for a in audits %}<tr><td>{{ a.id }}</td><td>{{ a.product_code }} · {{ a.description_snapshot or "" }}</td><td>{{ "Reversão" if a.action == "ROLLBACK" else "Preenchimento" }}</td><td>{{ L.outcome(a.outcome) }}{% if a.reason %} ({{ L.reason(a.reason) }}){% endif %}</td><td>{{ a.old_value or "vazio" }} → {{ a.new_value or "vazio" }}</td><td>{{ L.rule(a.rule_id) }}</td><td>{{ a.authorization_origin }}</td>
|
||||
<td>{% if a.action == "APPLY" and a.outcome == "APPLIED" and not a.rollback_state %}<form method="post" action="/agents/{{ agent_id }}/rtc-rollback" style="display:inline"><input type="hidden" name="csrf_token" value="{{ csrf_token }}"><input type="hidden" name="audit_id" value="{{ a.id }}"><input type="text" name="confirm" placeholder="digite REVERTER" size="12" aria-label="Confirmar reversão"><button type="submit" class="caution">Reverter</button></form>{% else %}{{ a.rollback_state or "" }}{% endif %}</td></tr>
|
||||
{% else %}<tr><td colspan="8" class="muted">Nenhum preenchimento registrado.</td></tr>{% endfor %}</tbody></table></section>
|
||||
{% else %}<tr><td colspan="8" class="muted">Nenhum preenchimento registrado.</td></tr>{% endfor %}</tbody></table></div></section>
|
||||
{% endblock %}
|
||||
|
||||
Reference in New Issue
Block a user