Replies: 1 comment
-
In my case, the problem was not obvious, in the documentation is not spelled out, but here the answer was given. I, for example, had this code: public function layout(): iterable
{
$layouts = [];
if ($this -> group -> exists)
{
$layouts[] = Layout::modal('studentEditModal', [
EditStudentRows::class,
])
-> async('asyncStudentEditModal');
}
}
public function asyncStudentEditModal(string $additionals): iterable
{
return [
'additionals' => $additionals,
];
} And it didn't work because the layout() method contained a condition. Asynchronous modal windows should be permanently rendered without any conditions: public function layout(): iterable
{
$layouts = [
Layout::modal('studentEditModal', [
EditStudentRows::class,
])
-> async('asyncStudentEditModal');
];
}
public function asyncStudentEditModal(string $additionals): iterable
{
return [
'additionals' => $additionals,
];
} References: #2047 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi I tried to implements async modal but got this 404 error.
Here is my code.
Modal
Modal Toggle
Async Method
Beta Was this translation helpful? Give feedback.
All reactions