mirror of
https://github.com/rickbarrette/simple-aircraft-manager-rails.git
synced 2026-11-17 23:50:36 -05:00
- Sign an entry: review exactly what's certified, choose a current certificate (eligibility checked: pilot only for preventive maintenance, inspections need their result and time), re-enter the password or sign in again with SSO (prompt=login, within 5 minutes), and confirm the "Certified by" statement (43.9 return to service, 43.11(a)(5) for inspections, preventive maintenance for pilots) - The signature stores signer, certificate, statement, UTC time, how they authenticated, IP/browser, a SHA-256 fingerprint of the entry's content and a readable snapshot; an HMAC seal covers the signature record. Status shows Valid / Superseded / Altered since signing. The signer is emailed - Signed entries (and their sub-components) can't be edited or deleted; a correction entry, once signed, supersedes the original (kept) - Owners invite an outside mechanic by email to sign one entry: one-time, 14-day link; they create or use their own account and certificate and see only that entry - Admins can disable accounts (signed out, can't sign in or sign; past signatures kept); users with signatures can't be deleted - Printouts show the electronic signature and fingerprint; archives carry signatures (marked imported, with their origin) and corrections Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
12 lines
1.0 KiB
ERB
12 lines
1.0 KiB
ERB
<% content_for :title, "Ask someone to sign" %>
|
|
<%= render "shared/aircraft_header", aircraft: @aircraft %>
|
|
<%= form_with model: @invitation, url: aircraft_logbook_entry_signing_invitations_path(@aircraft, @entry), class: "card card-body max-w-2xl space-y-4" do |f| %>
|
|
<h2 class="card-title">Ask someone to sign</h2>
|
|
<p class="text-sm text-slate-600">For a mechanic who did the work: they get a one-time link by email, sign in or create their own account, add their certificate, and sign this entry with their own password. They see only this entry.</p>
|
|
<%= f.errors_summary %>
|
|
<div class="rounded-md bg-slate-50 p-3 text-sm"><%= @entry.date %> · <%= LogbookEntry::LOG_TYPES[@entry.log_type] %> log · <%= @entry.text.truncate(160) %></div>
|
|
<%= f.field :email, as: :email, label: "Their email", required: true %>
|
|
<%= f.field :message, as: :textarea, rows: 2, label: "Message (optional)" %>
|
|
<div class="flex gap-2"><%= f.submit "Send invitation" %><%= link_to "Cancel", aircraft_logbook_entry_path(@aircraft, @entry), class: "btn-secondary" %></div>
|
|
<% end %>
|