Jul 8 - Implement Regenerate token and buik print QR codes
This commit is contained in:
@@ -16,9 +16,22 @@
|
||||
class="btn btn-outline-secondary btn-sm">
|
||||
<i class="bi bi-arrow-left"></i> Back to Facility
|
||||
</a>
|
||||
<button onclick="window.print()" class="btn btn-primary btn-sm">
|
||||
<i class="bi bi-printer"></i> Print
|
||||
</button>
|
||||
<div class="d-flex gap-2">
|
||||
{% if current_user.role in ['admin', 'director'] %}
|
||||
<form method="POST"
|
||||
action="{{ url_for('facilities.facility_qr_regenerate', facility_id=facility.id) }}"
|
||||
onsubmit="return confirm('Regenerate this QR code? Any codes already printed and posted for {{ facility.name }} will STOP working and must be reprinted.');">
|
||||
<input type="hidden" name="csrf_token" value="{{ csrf_token() }}">
|
||||
<button type="submit" class="btn btn-outline-danger btn-sm"
|
||||
title="Invalidate the current code and generate a new one">
|
||||
<i class="bi bi-arrow-repeat"></i> Regenerate
|
||||
</button>
|
||||
</form>
|
||||
{% endif %}
|
||||
<button onclick="window.print()" class="btn btn-primary btn-sm">
|
||||
<i class="bi bi-printer"></i> Print
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card shadow-sm qr-card">
|
||||
|
||||
Reference in New Issue
Block a user