Client report: show Spectora report inspectors in ReportHeader (not only Attik job inspectors)
Objective
- Align the Inspector block on the client report with Spectora’s
report.inspectorsdata (and charge / event assignment when that determines the displayed inspector for ancillary services), instead of defaulting to Attik work-order inspectors when that misrepresents the report.
Background
- Today
ReportHeaderprefers Attikinspection._inspectorId/inspectionInspectorsand only falls back toreport.inspectors, which diverges from how users read authorship in Spectora. - Some jobs may intentionally differ between Attik assignment and Spectora—Decision needed on fallback order when
report.inspectorsis empty.
Scope
Frontend
attik-frontend/src/app/client/reports/components/ReportHeader.tsxand any helpers that choose inspector display order from the report payload vs inspection population.
Backend / data
- Report JSON synced from Spectora/Firebase must continue to surface
report.inspectorson the object the client report receives; charge/event linkage used for “which inspector for this report section” should be traced from existing charge models (Decision needed on exact fields).
References
attik-frontend/src/app/client/reports/components/ReportHeader.tsx- Example job: https://www.attik.ai/inspections/1008590164?tab=workorder
Original description
Problem / request
Users expect the Inspector block on the Attik client report (ReportHeader) to reflect report.inspectors from the synced Spectora / Firebase report JSON (i.e. who Spectora associates with the report), similar to how they read it in Spectora.
Current behavior
ReportHeader prefers populated Attik work-order inspectors (inspection._inspectorId / inspectionInspectors) and only falls back to report.inspectors when those are not used. That can diverge from Spectora’s report inspector / author presentation.
Desired behavior
Use report.inspectors from the report payload for the Inspector block (possibly with a defined fallback order if the array is empty — product to confirm).
Use the charge assignment functionality to determine which inspector displays on the inspection report. i.e. if a sewer scope event is attached to the sewer scope inspector than the inspector for the event should be displayed on the report.
Example
https://www.attik.ai/inspections/1008590164?tab=workorder
Notes
- Code:
attik-frontend/src/app/client/reports/components/ReportHeader.tsx - Consider impact on jobs where Attik assignment and Spectora report inspectors intentionally differ.
Log in to comment and vote
No comments yet
Be the first to share your thoughts.