wip
This commit is contained in:
1 parent
2de7cb1504
commit
966b04dfa4
1 file changed
+13
-13
+13
-13
@@ -98,20 +98,20 @@ class MapperLeft extends Component implements HasActions, HasSchemas, HasTable
|
||||
->columns(4)
|
||||
->schema([
|
||||
FusedGroup::make([
|
||||
// Select::make('country_id')
|
||||
// ->placeholder('Country')
|
||||
// ->hiddenLabel()
|
||||
// ->searchable()
|
||||
// ->preload()
|
||||
// ->options(function () {
|
||||
// $res = Event::query()->where('sport_id', auth()->user()->sport_id)->where('betradar_id', 0)->where('starttime', '>', Carbon::now())->groupBy('country_id')->pluck('country_id')->toArray();
|
||||
Select::make('country_id')
|
||||
->placeholder('Country')
|
||||
->hiddenLabel()
|
||||
->searchable()
|
||||
->preload()
|
||||
->options(function () {
|
||||
$res = Event::query()->where('sport_id', auth()->user()->sport_id)->where('betradar_id', 0)->where('starttime', '>', Carbon::now())->groupBy('country_id')->pluck('country_id')->toArray();
|
||||
|
||||
// return Country::query()->whereIn('id', $res)->orderBy('name')->pluck('name', 'id');
|
||||
// })
|
||||
// ->afterStateUpdated(function (callable $set) {
|
||||
// $set('competition_group_id', null);
|
||||
// })
|
||||
// ->live(),
|
||||
return Country::query()->whereIn('id', $res)->orderBy('name')->pluck('name', 'id');
|
||||
})
|
||||
->afterStateUpdated(function (callable $set) {
|
||||
$set('competition_group_id', null);
|
||||
})
|
||||
->live(),
|
||||
// Select::make('competition_group_id')
|
||||
// ->placeholder('League')
|
||||
// ->hiddenLabel()
|
||||
|
||||
Reference in new issue
Block a user