charlie
charlie
FFilament
Created by charlie on 11/14/2024 in #❓┊help
$getRecord() in a form changes when I click on an action button or a relation manager tab
I'm curious about the reason behind this behaviour, and better alternatives if any
5 replies
FFilament
Created by charlie on 11/14/2024 in #❓┊help
$getRecord() in a form changes when I click on an action button or a relation manager tab
I solved it querying model again:
MyModel::find($getRecord()->id)
MyModel::find($getRecord()->id)
Not ideal, but surprisingly id keeps working unlike other attributes.
5 replies
FFilament
Created by charlie on 11/14/2024 in #❓┊help
$getRecord() in a form changes when I click on an action button or a relation manager tab
Unfortunately, adding wire:ignore prevents field to refresh (it makes sense)...
5 replies
FFilament
Created by charlie on 11/14/2024 in #❓┊help
$getRecord() in a form changes when I click on an action button or a relation manager tab
Solution: Adding wire:ignore to the parent div seems to do the trick!
5 replies
FFilament
Created by charlie on 10/24/2024 in #❓┊help
Can't use $get inside recordSelectOptionsQuery: any workaround?
Hi, not sure what you mean, but if I do it like that, $data returns an empty array:
->recordSelectOptionsQuery(
function (Builder $query, $livewire, $data) {
dump($data); // returns []
// ...
}
)
->recordSelectOptionsQuery(
function (Builder $query, $livewire, $data) {
dump($data); // returns []
// ...
}
)
4 replies