Skip to content

click cell to view related resource item? #6065

Closed Answered by wivaku
wivaku asked this question in Help
Discussion options

You must be logged in to vote

Oops... did not catch this in the documentation. Apologies!
https://filamentphp.com/docs/2.x/tables/columns/getting-started#opening-urls

I ended up using a slight variation, as in my case not every "Order" has a "Customer".

                    ->url(function ($record) {
                        return $record->customer
                            ? CustomerResource::getUrl('view', ['record' => $record->customer])
                            : null;
                    })

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by wivaku
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Help
Labels
None yet
3 participants