diff --git a/app/routes/documents.py b/app/routes/documents.py index 62e4e90..9492019 100644 --- a/app/routes/documents.py +++ b/app/routes/documents.py @@ -940,7 +940,7 @@ def save_document_type_route( document.document_type = document_type.strip() or None db.commit() - return RedirectResponse(url=f"/documents/{document.document_id}?tab=ocr-review&success=rerun_ocr", status_code=303) + return RedirectResponse(url=f"/documents/{document.document_id}?tab=ocr-review&success=saved_document_type", status_code=303) @router.post("/{document_id}/rerun-ocr", response_class=RedirectResponse) @@ -1650,7 +1650,7 @@ def document_detail(document_id: str, request: Request, queue: str | None = None ] active_tab = request.query_params.get("tab", "ocr-review") - if active_tab not in {"ocr-review", "extracted-fields", "additional-fields", "versions", "raw-ocr", "source-options"}: + if active_tab not in {"ocr-review", "extracted-fields", "additional-fields", "line-items", "versions", "raw-ocr", "source-options"}: active_tab = "ocr-review" return templates.TemplateResponse( diff --git a/app/static/app.css b/app/static/app.css index 548dff7..083b275 100644 --- a/app/static/app.css +++ b/app/static/app.css @@ -4219,3 +4219,42 @@ table { + + +/* ===== save document far right ===== */ +@media (max-width: 900px) { + .detail-sticky-header .queue-nav-row::before { + order: 99 !important; + margin-left: auto !important; + } +} +/* ===== end save document far right ===== */ + + +/* ===== save button blue + nav row spacing ===== */ +@media (max-width: 900px) { + .detail-sticky-header .queue-nav-row { + display: flex !important; + flex-wrap: wrap !important; + align-items: center !important; + gap: 0.14rem !important; + row-gap: 0.12rem !important; + } + + .detail-sticky-header .queue-nav-row .button-link, + .detail-trash-inline button { + margin: 0 !important; + } + + .detail-sticky-header .queue-nav-row::before { + order: 99 !important; + margin-left: auto !important; + + background: #2563eb !important; + color: #ffffff !important; + border-color: #2563eb !important; + + box-shadow: none !important; + } +} +/* ===== end save button blue + nav row spacing ===== */ diff --git a/app/templates/base.html b/app/templates/base.html index e701e72..2809cea 100644 --- a/app/templates/base.html +++ b/app/templates/base.html @@ -4,7 +4,7 @@