mirror of
https://github.com/rickbarrette/simple-aircraft-manager-rails.git
synced 2026-11-17 15:50:36 -05:00
- Squawks: defer an inoperative item under 91.213(d) once each condition is confirmed (pilots may too); deferred items stop grounding and are listed for awareness. Resolving can record the fix as a logbook entry (43.9 fields) or link an existing one - Expiration dates on components (ELT battery, 91.207(c)) and documents; new document types (registration, airworthiness certificate, insurance, radio license). Expired replacement-critical parts and an expired registration (91.203) ground; others warn; registration warns 90 days out - Standard inspections: one click adds annual, 100-hour, 91.411, 91.413, ELT (91.207(d)) and VOR (91.171) checks with the right rules, skipping ones already tracked and linking annual to 100-hour - Weekly Monday reminder email to owners when something needs attention; profile opt-out; admin "send me this week's reminder" - README feature table updated Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
32 lines
1.5 KiB
ERB
32 lines
1.5 KiB
ERB
<% content_for :title, "#{@aircraft.tail_number} Squawks" %>
|
|
<%= render "shared/aircraft_header", aircraft: @aircraft %>
|
|
<section class="card">
|
|
<div class="card-header">
|
|
<h2 class="card-title">Open Squawks</h2>
|
|
<%= link_to "+ Report Squawk", new_aircraft_squawk_path(@aircraft), class: "btn-primary" %>
|
|
</div>
|
|
<% if @active.any? %><%= render "squawks/table", squawks: @active, aircraft: @aircraft %><% else %><%= empty_state "No open squawks." %><% end %>
|
|
</section>
|
|
|
|
<section class="card mt-5">
|
|
<div class="card-header"><h2 class="card-title">Resolved</h2></div>
|
|
<% if @resolved.any? %>
|
|
<table class="table">
|
|
<thead><tr><th>Priority</th><th>Issue</th><th>Resolution</th><th>Resolved</th><th></th></tr></thead>
|
|
<tbody>
|
|
<% @resolved.each do |s| %>
|
|
<tr>
|
|
<td><%= squawk_priority_badge(s) %></td>
|
|
<td><%= s.issue_reported %><%= render "squawks/attachments", squawk: s %></td>
|
|
<td class="text-xs text-slate-600"><%= s.notes %><% if s.logbook_entry %><div><%= link_to "Logbook #{s.logbook_entry.date}", aircraft_logbook_entry_path(@aircraft, s.logbook_entry), class: "link" %></div><% end %></td>
|
|
<td class="text-xs text-slate-500"><%= s.resolved_at&.to_date %></td>
|
|
<td class="text-right"><% if owner? %><%= button_to "Reopen", reopen_aircraft_squawk_path(@aircraft, s), method: :patch, class: "btn-secondary btn-sm" %><% end %></td>
|
|
</tr>
|
|
<% end %>
|
|
</tbody>
|
|
</table>
|
|
<% else %>
|
|
<%= empty_state "No resolved squawks." %>
|
|
<% end %>
|
|
</section>
|