feat(web): UI compact Trimiteri + bara bulk contextuala + fix buton "+" editor (PRD 5.22)
Trimiteri desktop = tabel grid cu header, un rand per trimitere: status = bulina cu tooltip, mediu = litera T/P, multi-cod = primul cod + badge +N, sub-linie de eroare cu textul brut RAR doar pe error/needs_data. Mobil: 2 linii prin grid-areas, fara header. Actiunile bulk apar doar la selectie (bara contextuala cu contor + texte explicite). Mapari: exemplu concret in loc de descriere la Reguli automate. Fix buton "+" chips (nu facea nimic, fara eroare): hx-disabled-elt="find button" mostenit de la form-ul parinte crapa htmx inainte de request -> hx-disabled-elt="this" explicit pe butoanele chips; separat, no-op-urile silentioase din post_form_chips au acum mesaje (cod invalid/duplicat) si confirmare cu chip evidentiat la succes. Suita: 1622 passed. Verify E2E in browser (desktop 1280 + mobil 390). Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -186,15 +186,16 @@ def test_operatie_contine_cod_rar(client):
|
||||
|
||||
|
||||
def test_pill_eticheta_scurta(client):
|
||||
"""Pill-ul de Stare foloseste eticheta scurta; textul lung in title."""
|
||||
"""Statusul e bulina colorata (dot-stare); textul complet al starii in title."""
|
||||
acct = _create_account_user("pill@test.com")
|
||||
_insert_submission(acct, "sent", id_prezentare=70001)
|
||||
_login(client, "pill@test.com")
|
||||
resp = client.get("/_fragments/submissions")
|
||||
assert resp.status_code == 200
|
||||
html = resp.text
|
||||
# eticheta scurta in pill
|
||||
assert ">Finalizat<" in html
|
||||
# bulina cu clasa de stare, fara text in celula
|
||||
assert "dot-stare" in html
|
||||
assert "s-sent" in html
|
||||
# textul lung pastrat ca tooltip (title)
|
||||
assert 'title="Declarate la RAR' in html
|
||||
|
||||
@@ -229,8 +230,8 @@ def test_eticheta_umana_apare_sub_pill(client):
|
||||
resp = client.get("/_fragments/submissions")
|
||||
assert resp.status_code == 200
|
||||
html = resp.text
|
||||
assert "eticheta-problema" in html # containerul textului uman sub pill
|
||||
assert "s-error" in html # colorat ca problema (error/needs_*)
|
||||
assert "c-err" in html # sub-linia compacta de eroare
|
||||
assert "lipsa odometru" in html # textul brut al erorii, nu eticheta explicativa
|
||||
# NU randeaza cod brut de catalog pe rand
|
||||
assert "COD_" not in html
|
||||
assert "RAR_EROARE" not in html
|
||||
@@ -444,16 +445,17 @@ def test_rand_slim_vin_operatie_pill(client):
|
||||
assert "slim-vin" in html, "slim-vin lipseste — linia 1 placuta"
|
||||
assert "B777ZZZ" in html, "placuta (nr. inmatriculare) lipseste de pe rand"
|
||||
|
||||
# L2: cod RAR · operatie · data (slim-meta / slim-rand2)
|
||||
assert "slim-meta" in html, "slim-meta lipseste — linia 2"
|
||||
assert "slim-rand2" in html, "slim-rand2 lipseste — linia 2 (cod RAR · operatie · data)"
|
||||
# Celulele: cod RAR · operatie · data (c-meta cu c-cod/c-op/c-data)
|
||||
assert "c-meta" in html, "c-meta lipseste — celulele cod/operatie/data"
|
||||
assert "c-cod" in html and "c-op" in html, "celulele cod/operatie lipsesc"
|
||||
|
||||
# VIN integral nu mai e pe rand — traieste in modalul de detaliu.
|
||||
assert "000777" not in html, "VIN scurt nu mai trebuie randat pe randul slim (2 linii)"
|
||||
|
||||
# Pill de stare: clasa CSS + eticheta scurta
|
||||
assert "s-sent" in html, "clasa pill s-sent lipseste"
|
||||
assert "Finalizat" in html, "eticheta scurta stare_scurt lipseste"
|
||||
# Status: bulina cu clasa de stare; numele coloanei in header
|
||||
assert "s-sent" in html, "clasa de stare s-sent lipseste"
|
||||
assert "dot-stare" in html, "bulina de status lipseste"
|
||||
assert "Status" in html, "headerul coloanei Status lipseste"
|
||||
|
||||
|
||||
def test_filtre_paginare_pastrate(client):
|
||||
|
||||
Reference in New Issue
Block a user