Skip to content

Commit

Permalink
fix: use getRouteKey for resource page
Browse files Browse the repository at this point in the history
  • Loading branch information
akki-io authored Aug 9, 2024
1 parent a9bea72 commit 7bdabd6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Commands/ResourceCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ public function searchRecord($query): EloquentCollection|Collection|array
->limit(50)
->get()
->map(fn (Model $record) => new SpotlightSearchResult(
$record->getKey(),
$record->getRouteKey(),
$resource::getGlobalSearchResultTitle($record),
collect($resource::getGlobalSearchResultDetails($record))
->map(fn ($value, $key) => $key.': '.$value)
Expand Down

0 comments on commit 7bdabd6

Please sign in to comment.