reload \ refresh relation manager table on page action
Is there not an easy way to refresh the a table displayed by a relation manager, when an action on the resource view page completes ?
4 Replies
Register an event in the relation manager class
https://livewire.laravel.com/docs/events#listening-for-events
Dispatch it from your action
Laravel
Events | Laravel
A full-stack framework for Laravel that takes the pain out of building dynamic UIs.
@Leandro Ferreira, thanks for this help.
I've managed to make it jump to a function using
$this->dispatch('refreshInvoiceLinesTable');
Then within the relationManager, something like:
However, I don't what the code needs to be to actually force the refresh of that table.
I've had a look through various documentations, but my livewire knowledge is very basic.
Appreciate any pointing or specific guidance on this.
bumpSolution
Yes, this works, Thanks.
Also this works: