"Live" Relationship Manager?
Is it possible to add a livewire poll to a relationship manager so that it shows the "live" data? or better still, trigger an update of the RelationshipManager when a field in the Resource has been updated? Like, when I save the resource, force the RM to update?
As you can see in the screenshot, the
query
on my Reporting Rulesets is a fuzzy-match for the Orders model, and currently I'm only able to see the updated list upon refreshing the page.
5 Replies
What is the code for your select?
Do you mean the query? It's a modified
hasMany()
relationshipEssentially just calling orders like it's a normal relationship - but having a % changes it to an
orWhere
query to return more results
OK so I've found the
$table->poll('1s')
method which works great - but if anyone can point me at a way to trigger a manual update upon saving the main Model, that would be more efficient as I don't need it to be querying the database regularly, but I would need to update my Relation Manager when saving the query
property on my modelYou can dispatch a livewire event, see : https://discord.com/channels/883083792112300104/1148829601271914576