@maticl
RelationManager table action always injects the same record
What I am trying to do:
On a relation manager I have a table action, that displays audit log details.
Not all audit logs have details view, so I dynamically resolve content and visibility based on audit log class.
If you need any more context feel free to ask.
What I did:
I cleared every cache, debugged it, everything seems fine except the injection.
If I log the record in modalContent callback, it always points to the record of the first row in the table (even if we go to page 2, it will point to the record of first row on page 1).
The developer tools network logs dispatch the correct events with correct ids.
log_instance is an Attribute on AuditLog model, that resolves the audit type class with all the data.
My issue/the error:
For some reason, the action modalContent and modalWidth callbacks always get injected with the same record (model of the first row in the table).
Visibility callback works okay.
Code:
3 replies