fix(reports): stop the daily financial print 500ing on any day with a payment
dailyFinancial() eager-loaded `createdBy` on Payment. That relation does not
exist — Payment names it `creator`, after the person rather than the column,
and the print view has always read `$payment->creator`. Eloquent throws
RelationNotFoundException on an eager load it cannot resolve, so this was not
a missed optimisation: the report 500'd on every date that had a confirmed
inbound payment and only rendered on an empty day, which is why it survived.
Caught by BranchScopedScreensTest, which renders every staff screen; it had
been failing on reports.daily-print.
Co-Authored-By:
Claude Opus 5 (1M context) <noreply@anthropic.com>
Showing
Please register or sign in to comment