feat(membership): print button + print-optimized CSS for declarations
Some checks are pending
NordaBiz Tests / Unit & Integration Tests (push) Waiting to run
NordaBiz Tests / E2E Tests (Playwright) (push) Blocked by required conditions
NordaBiz Tests / Smoke Tests (Production) (push) Blocked by required conditions
NordaBiz Tests / Send Failure Notification (push) Blocked by required conditions
Some checks are pending
NordaBiz Tests / Unit & Integration Tests (push) Waiting to run
NordaBiz Tests / E2E Tests (Playwright) (push) Blocked by required conditions
NordaBiz Tests / Smoke Tests (Production) (push) Blocked by required conditions
NordaBiz Tests / Send Failure Notification (push) Blocked by required conditions
- Blue "Drukuj deklarację" button in action sidebar (submitted + under_review) - @media print CSS: hides nav, sidebar, buttons; full-width main content - Print header with chamber name, declaration number, date, status - Clean data sections for paper output - Uses native window.print() — browser shows printer selection dialog Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
77f5277372
commit
d889444fab
@ -537,10 +537,56 @@
|
||||
background: var(--background);
|
||||
border-radius: var(--radius);
|
||||
}
|
||||
|
||||
/* Print styles */
|
||||
@media print {
|
||||
/* Hide navigation, sidebar actions, admin bar, buttons, modals */
|
||||
nav, .admin-bar, .sidebar, .action-buttons, .action-help,
|
||||
.modal, .modal-overlay, .alert, .btn-action, .btn-back,
|
||||
footer, .notifications-menu, .user-menu, .breadcrumb,
|
||||
.workflow-timeline, .detail-header .status-badge { display: none !important; }
|
||||
|
||||
/* Full width for main content */
|
||||
.content-grid { display: block !important; }
|
||||
.main-content { width: 100% !important; max-width: 100% !important; }
|
||||
|
||||
/* Clean print header */
|
||||
body { font-size: 11pt; color: #000; background: #fff; }
|
||||
.detail-header h1 { font-size: 16pt; margin-bottom: 4pt; }
|
||||
|
||||
/* Print header with logo and title */
|
||||
.print-header {
|
||||
display: block !important;
|
||||
text-align: center;
|
||||
margin-bottom: 20pt;
|
||||
padding-bottom: 10pt;
|
||||
border-bottom: 2px solid #2E4872;
|
||||
}
|
||||
.print-header h2 { font-size: 14pt; color: #2E4872; margin: 0; }
|
||||
.print-header p { font-size: 10pt; color: #666; margin: 4pt 0 0; }
|
||||
|
||||
/* Data sections clean */
|
||||
.info-section { break-inside: avoid; margin-bottom: 12pt; border: 1px solid #ddd; padding: 8pt; }
|
||||
.info-section h2 { font-size: 12pt; color: #2E4872; border-bottom: 1px solid #2E4872; padding-bottom: 4pt; }
|
||||
.info-row { padding: 2pt 0; }
|
||||
.info-label { font-weight: bold; }
|
||||
|
||||
/* Page setup */
|
||||
@page { margin: 15mm; }
|
||||
}
|
||||
|
||||
/* Hidden in screen, visible in print */
|
||||
.print-header { display: none; }
|
||||
</style>
|
||||
{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
<div class="print-header">
|
||||
<h2>Izba Gospodarcza Norda Biznes</h2>
|
||||
<p>Deklaracja członkowska nr {{ application.id }} — {{ application.company_name }}</p>
|
||||
<p>Data złożenia: {{ application.submitted_at.strftime('%d.%m.%Y, %H:%M') if application.submitted_at else 'brak' }} | Status: {{ application.status_label }}</p>
|
||||
</div>
|
||||
|
||||
<a href="{{ url_for('admin.admin_membership') }}" class="back-link">
|
||||
← Powrót do listy deklaracji
|
||||
</a>
|
||||
@ -777,6 +823,9 @@
|
||||
<button class="btn-action btn-review" onclick="startReview()">
|
||||
Rozpocznij rozpatrywanie
|
||||
</button>
|
||||
<button class="btn-action" onclick="window.print()" style="background: var(--primary); color: white; margin-top: 8px;">
|
||||
🖨 Drukuj deklarację
|
||||
</button>
|
||||
</div>
|
||||
<p class="action-help">
|
||||
Zmieni status na "W trakcie rozpatrywania" i odblokuje opcje zatwierdzenia, odrzucenia lub prośby o poprawki.
|
||||
@ -822,6 +871,9 @@
|
||||
<button class="btn-action btn-reject" onclick="openRejectModal()">
|
||||
✗ Odrzuć
|
||||
</button>
|
||||
<button class="btn-action" onclick="window.print()" style="background: var(--primary); color: white; margin-top: 8px;">
|
||||
🖨 Drukuj deklarację
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<div class="form-group" style="margin-top: var(--spacing-lg);">
|
||||
|
||||
Loading…
Reference in New Issue
Block a user