bbs-lab/nova-action-event-columns
A Laravel Nova package that adds action event columns to your resources, making action and event data easier to display, scan, and review directly in Nova tables. Useful for quick visibility into recorded action activity and debugging workflows without writing custom column code.
Architecture fit
action_events table remains the single source of truth for who did what, which keeps existing audit queries, Nova's ActionResource screens, and any downstream reporting intact.ip_address add-on into a reusable extension point for tenancy, user-agent, request correlation IDs, or compliance tags without forking Nova or maintaining a patched vendor tree.creating hook + query-builder insert() override) is deliberately chosen to catch the mass-insert paths (delete, force-delete, restore, custom actions) that bypass Eloquent events. This is the correct problem to solve, but it is also the main architectural coupling.ActionResource, meaning the package owns a piece of Nova's presentation layer. That is what makes the columns visible with sensible defaults, but it also means we inherit responsibility for that resource staying in step with Nova's own.Integration feasibility
action_events, register the resource in NovaServiceProvider. No service container gymnastics, no Nova fork.action_events is a Nova-owned table; our additive migration must run after Nova's, and we should treat any future Nova migration touching that table as a potential conflict to re-verify on upgrade.tenant_id is the obvious candidate for multi-tenant installs) without waiting on upstream releases.Technical risk
insert() on Nova's ActionEvent model depends on Nova continuing to route mass inserts through that model. If a future Nova release switches to DB::table('action_events')->insert(), coverage degrades silently — actions still succeed, columns are simply null. Silent audit gaps are the worst failure mode for this class of package.creating hook or insert() override could abort the user's action. We need to confirm whether failures are swallowed, logged, or propagated — and set a policy (almost certainly: log and write null, never block the action).request()->ip() honours TrustProxies. Behind an ALB/Cloudflare, a misconfigured proxy list yields the load balancer's IP for every event — plausible-looking data that is quietly wrong. Verify in staging, not production.Key questions
insert() override preserve batch semantics and per-row values correctly for multi-row inserts, and what is the per-row overhead?ActionResource a full replacement for Nova's, and what do we lose or gain in sortable/filterable fields?Stack fit
action_events table.tenant_id via the column registry is the natural first custom column and likely the single highest-value use of this package beyond IP capture.Migration path
ActionResource, (4) enable ip_address in config, (5) add tenant_id via the stub once the base install is proven.Compatibility
TrustProxies configuration before trusting IP values, and confirm our Nova version is within ^4.0 || ^5.0.action_events during Nova minor upgrades.Sequencing
ip_address only, at low blast radius, before adding custom columns.tenant_id and any compliance columns once baseline confidence is established.Maintenance
Support
Scaling
action_events is already append-only and was going to grow; the added columns are narrow scalars and add negligible row width. The real growth concern is event volume, which the prune command addresses.tenant_id becomes a common filter in the ActionResource, it likely warrants an index.Failure modes
--days policy should be a written decision, not a scheduler default.action_events.Ramp-up
How can I help you explore Laravel packages today?