This commit is contained in:
Muhammad Tamir
2025-11-14 11:01:38 +07:00
parent 549cc6c039
commit a887530b41
90 changed files with 684 additions and 614 deletions

View File

@@ -19,6 +19,8 @@ class UserComponent extends Select
->getOptionLabelFromRecordUsing(fn ($record) => $record->name . ' (' . $record->email . ')')
->getSearchResultsUsing(fn (string $search): array => User::where('first_name', 'like', "%$search%")
->orWhere('last_name', 'like', "%$search%")
->orWhere('email', 'like', "%$search%")
->orWhere('id', 'like', "%$search%")
->limit(50)
->get()
->mapWithKeys(fn ($user) => [$user->id => $user->name . ' (' . $user->email . ')'])