i'm trying to make a form modal when you click on a button in the header of an infolist this is the code example
public function productInfolist(Infolist $infolist): Infolist { return $infolist->record($this->post)->schema([ Section::make("View Post") ->headerActions([ Action::make('submitForm') ->form([ TextInput::make('exampleField') ->label('Example Field') ->required(), ]) // ^^^^^^ this doesnt works ->action(function (array $data) { // Handle form submission here // For example, save $data to a database }), Action::make("Book2")->url(fn(): string => route('booking', ['post_id' => $this->post_id])) // ^^^^^^ this works ])// .....
public function productInfolist(Infolist $infolist): Infolist { return $infolist->record($this->post)->schema([ Section::make("View Post") ->headerActions([ Action::make('submitForm') ->form([ TextInput::make('exampleField') ->label('Example Field') ->required(), ]) // ^^^^^^ this doesnt works ->action(function (array $data) { // Handle form submission here // For example, save $data to a database }), Action::make("Book2")->url(fn(): string => route('booking', ['post_id' => $this->post_id])) // ^^^^^^ this works ])// .....
there may be an issue with the admin panel before you need a google maps api key to access the route /center but the question i'm asking has nothing to do with the panel that lives in route /center, it has to do only with the route /posts/{post_id}